Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Fetching contributors…

Cannot retrieve contributors at this time

26 lines (20 sloc) 0.501 kB
require 'capybara'
require 'capybara/dsl'
require 'capybara/rspec/matchers'
World(Capybara::DSL)
World(Capybara::RSpecMatchers)
Before do
Capybara.reset_sessions!
Capybara.use_default_driver
end
Before '@javascript' do
Capybara.current_driver = Capybara.javascript_driver
end
Before do |scenario|
scenario.source_tag_names.each do |tag|
driver_name = tag.sub(/^@/, '').to_sym
if Capybara.drivers.has_key?(driver_name)
Capybara.current_driver = driver_name
end
end
end
Jump to Line
Something went wrong with that request. Please try again.