mirror of
https://github.com/teamcapybara/capybara.git
synced 2022-11-09 12:08:07 -05:00
Fix Chrome download settings
This commit is contained in:
parent
a76a35fbc8
commit
5d24424b13
1 changed files with 2 additions and 1 deletions
|
@ -14,7 +14,8 @@ browser_options = ::Selenium::WebDriver::Chrome::Options.new
|
|||
browser_options.headless! if ENV['HEADLESS']
|
||||
browser_options.add_option(:w3c, ENV['W3C'] != 'false')
|
||||
# Chromedriver 77 requires setting this for headless mode on linux
|
||||
# browser_options.add_preference('download.default_directory', Capybara.save_path)
|
||||
# Different versions of Chrome/selenium-webdriver require setting differently - jus set them all
|
||||
browser_options.add_preference('download.default_directory', Capybara.save_path)
|
||||
browser_options.add_preference(:download, default_directory: Capybara.save_path)
|
||||
|
||||
Capybara.register_driver :selenium_chrome do |app|
|
||||
|
|
Loading…
Reference in a new issue