-
Notifications
You must be signed in to change notification settings - Fork 3
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Cukes via Docker - selenium (Chrome in a container)
- Loading branch information
Mark Sutton
committed
Jan 5, 2021
1 parent
e7c2376
commit e3bc613
Showing
4 changed files
with
94 additions
and
5 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,17 @@ | ||
require 'selenium/webdriver' | ||
|
||
Capybara.register_driver :selenium_chrome_in_container do |app| | ||
Capybara::Selenium::Driver.new app, | ||
browser: :remote, | ||
url: 'http://selenium_chrome:4444/wd/hub', | ||
desired_capabilities: :chrome | ||
end | ||
|
||
Capybara.register_driver :headless_selenium_chrome_in_container do |app| | ||
Capybara::Selenium::Driver.new app, | ||
browser: :remote, | ||
url: 'http://selenium_chrome:4444/wd/hub', | ||
desired_capabilities: Selenium::WebDriver::Remote::Capabilities.chrome( | ||
chromeOptions: { args: %w[headless disable-gpu] } | ||
) | ||
end |