Rails + Capybara + Selenium + Chrome Driver setup

Just setup our Capybara tests to use Chrome driver. Here is how I did it. First, added group :test do gem 'capybara' gem 'selenium-webdriver' gem 'chromedriver-helper' #<- New! end Then in the spec_helper.rb Capybara.register_driver :selenium do |app| Capybara::Selenium::Driver.new(app, browser: :chrome) end Capybara.javascript_driver = :chrome Capybara.configure do |config| config.default_max_wait_time = 10 # seconds config.default_driver = :selenium end Finally, w
1 min read