The Economic Hitmen.
Proud to be member of eSpace and work on the interactive results map of the Egyptian referendum 2012.
Bottle Bank Arcade - TheFunTheory.com
Daylight Saving Time Explained
Two Muslim brothers, one all-American success story.
Jetstrap is the fastest and easiest way to build Twitter Bootstrap interfaces and designs.
Using Chrome to run Capybara/Selenium Tests
When you setup Capybara and Selenium with RSpec on Rails, your tests will run in Firefox by default. However, I recently noticed that many tests result in timeout errors that seemed to be a result of slow loading of Ajax elements, so I decided to try Chrome instead.
- Download ChromeDriver for your platform
- Include the ChromeDriver location in your PATH environment variable, or copy it to a location that’s already in your path such as /usr/local/bin/
- Make sure it’s executable:
sudo chmod +x /usr/local/bin/chromedriver
- Add the following to your spec_helper.rb:
Capybara.register_driver :selenium do |app|Capybara::Selenium::Driver.new(app, :browser => :chrome)
Now, if you run
rake spec, Chrome should automatically fire up and run your test with Selenium.