mirror of
https://github.com/openSUSE/osem.git
synced 2026-08-13 19:54:02 +00:00
The "chromeOptions" key in chrome capabilities changed to "goog:chromeOptions".
But I'm rather switching to the 'option' array here for readability and alignment with Firefox options.
This commit is contained in:
parent
046ed9f7b7
commit
f5ac859b9b
1 changed files with 6 additions and 6 deletions
|
|
@ -78,12 +78,12 @@ RSpec.configure do |config|
|
|||
end
|
||||
|
||||
Capybara.register_driver :chrome_headless do |app|
|
||||
capabilities = Selenium::WebDriver::Remote::Capabilities.chrome(
|
||||
chromeOptions: { args: %w(headless disable-gpu window-size=1920x1080 no-sandbox) }
|
||||
)
|
||||
Capybara::Selenium::Driver.new(
|
||||
app, browser: :chrome, desired_capabilities: capabilities
|
||||
)
|
||||
options = ::Selenium::WebDriver::Chrome::Options.new
|
||||
options.args << '--window-size=1920x1080'
|
||||
options.args << '--headless'
|
||||
options.args << '--no-sandbox'
|
||||
options.args << '--disable-gpu'
|
||||
Capybara::Selenium::Driver.new(app, browser: :chrome, options: options)
|
||||
end
|
||||
|
||||
Capybara.default_max_wait_time = 10 # seconds
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue