Sha256: 9eea21dca3ae9bb3c7cd13a2a6326b4d43bcda95366606ae84b26897ef7e05f7

Contents?: true

Size: 989 Bytes

Versions: 7

Compression:

Stored size: 989 Bytes

Contents

require 'capybara-screenshot/rspec'

Capybara.save_path = ENV['CIRCLE_ARTIFACTS'] if ENV['CIRCLE_ARTIFACTS']

if ENV['WEBDRIVER'] == 'accessible'
  require 'capybara/accessible'
  Capybara.javascript_driver = :accessible
else
  Capybara.register_driver :chrome do |app|
    Selenium::WebDriver.logger.level = :error

    Capybara::Selenium::Driver.new app,
      browser: :chrome,
      options: Selenium::WebDriver::Chrome::Options.new(
        args: %w[no-sandbox disable-dev-shm-usage disable-popup-blocking headless disable-gpu window-size=1920,1080 --enable-features=NetworkService,NetworkServiceInProcess --disable-features=VizDisplayCompositor],
        log_level: :error
      )
  end
  Capybara.javascript_driver = :chrome

  Capybara::Screenshot.register_driver(:chrome) do |driver, path|
    driver.browser.save_screenshot(path)
  end
end
Capybara.default_max_wait_time = ENV.fetch('CAPYBARA_MAX_WAIT_TIME', 45).to_i
Capybara.server = :puma

Capybara.always_include_port = true

Version data entries

7 entries across 7 versions & 1 rubygems

Version Path
spree_core-4.3.3 lib/spree/testing_support/capybara_config.rb
spree_core-4.3.2 lib/spree/testing_support/capybara_config.rb
spree_core-4.3.1 lib/spree/testing_support/capybara_config.rb
spree_core-4.3.0 lib/spree/testing_support/capybara_config.rb
spree_core-4.3.0.rc3 lib/spree/testing_support/capybara_config.rb
spree_core-4.3.0.rc2 lib/spree/testing_support/capybara_config.rb
spree_core-4.3.0.rc1 lib/spree/testing_support/capybara_config.rb