Created
April 20, 2012 16:26
-
-
Save jumski/2430122 to your computer and use it in GitHub Desktop.
rspec around hook for runnign selenium_chrome with headless gem in capybara
This file contains hidden or 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
c.around(:each, :js => true) do |example| | |
if Capybara.current_driver == :chrome | |
headless = Headless.new | |
headless.start | |
end | |
example.run | |
headless.destroy if Capybara.current_driver == :chrome | |
end |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment