Sha256: 7b0056f0f896973251f663923c1970f830db3c971bf7ffbc8a54ae2da8fba365

Contents?: true

Size: 572 Bytes

Versions: 65

Compression:

Stored size: 572 Bytes

Contents

Capybara.register_driver :agilibox_chrome_headless do |app|
  window_size = Agilibox::CucumberConfig.window_size.map(&:to_s).join(",")

  capabilities = Selenium::WebDriver::Remote::Capabilities.chrome(
    :chromeOptions => {args: %W(headless window-size=#{window_size})},
  )

  Capybara::Selenium::Driver.new(app,
    :browser              => :chrome,
    :desired_capabilities => capabilities,
  )
end

Capybara.default_driver    = :agilibox_chrome_headless
Capybara.current_driver    = :agilibox_chrome_headless
Capybara.javascript_driver = :agilibox_chrome_headless

Version data entries

65 entries across 65 versions & 1 rubygems

Version Path
agilibox-1.5.8 lib/agilibox/cucumber_helpers/chrome_headless.rb
agilibox-1.5.7 lib/agilibox/cucumber_helpers/chrome_headless.rb
agilibox-1.5.6 lib/agilibox/cucumber_helpers/chrome_headless.rb
agilibox-1.5.5 lib/agilibox/cucumber_helpers/chrome_headless.rb
agilibox-1.5.4 lib/agilibox/cucumber_helpers/chrome_headless.rb
agilibox-1.5.3 lib/agilibox/cucumber_helpers/chrome_headless.rb
agilibox-1.5.2 lib/agilibox/cucumber_helpers/chrome_headless.rb
agilibox-1.5.1 lib/agilibox/cucumber_helpers/chrome_headless.rb
agilibox-1.5.0 lib/agilibox/cucumber_helpers/chrome_headless.rb
agilibox-1.4.4 lib/agilibox/cucumber_helpers/chrome_headless.rb
agilibox-1.4.3 lib/agilibox/cucumber_helpers/chrome_headless.rb
agilibox-1.4.2 lib/agilibox/cucumber_helpers/chrome_headless.rb
agilibox-1.4.1 lib/agilibox/cucumber_helpers/chrome_headless.rb
agilibox-1.4.0 lib/agilibox/cucumber_helpers/chrome_headless.rb
agilibox-1.3.6 lib/agilibox/cucumber_helpers/chrome_headless.rb
agilibox-1.3.5 lib/agilibox/cucumber_helpers/chrome_headless.rb
agilibox-1.3.4 lib/agilibox/cucumber_helpers/chrome_headless.rb
agilibox-1.3.3 lib/agilibox/cucumber_helpers/chrome_headless.rb
agilibox-1.3.2 lib/agilibox/cucumber_helpers/chrome_headless.rb
agilibox-1.3.1 lib/agilibox/cucumber_helpers/chrome_headless.rb