mirror of
https://github.com/openfoodfoundation/openfoodnetwork
synced 2026-02-13 23:37:47 +00:00
Sets cuprite as default; sets rack_test in before/after blocks
This commit is contained in:
@@ -5,7 +5,7 @@ require "system_helper"
|
||||
describe '
|
||||
As an administrator
|
||||
I want to print a invoice as PDF
|
||||
', type: :feature, js: false do
|
||||
', type: :feature do
|
||||
include WebHelper
|
||||
include AuthenticationHelper
|
||||
|
||||
@@ -27,9 +27,14 @@ describe '
|
||||
end
|
||||
|
||||
before do
|
||||
Capybara.current_driver = :rack_test
|
||||
stub_request(:get, ->(uri) { uri.to_s.include? "/css/mail" })
|
||||
end
|
||||
|
||||
after do
|
||||
Capybara.use_default_driver
|
||||
end
|
||||
|
||||
describe "that contains right Payment Description at Checkout information" do
|
||||
let!(:payment_method1) do
|
||||
create(:stripe_sca_payment_method, distributors: [distributor], description: "description1")
|
||||
|
||||
@@ -22,7 +22,7 @@ Capybara.register_driver(:cuprite) do |app|
|
||||
end
|
||||
|
||||
# Configure Capybara to use :cuprite driver by default
|
||||
Capybara.javascript_driver = :cuprite
|
||||
Capybara.default_driver = Capybara.javascript_driver = :cuprite
|
||||
|
||||
RSpec.configure do |config|
|
||||
config.include CupriteHelpers, type: :system
|
||||
|
||||
Reference in New Issue
Block a user