2009-11-16 16:02:16 -05:00
|
|
|
require 'capybara'
|
|
|
|
require 'capybara/dsl'
|
2011-02-06 08:44:43 -05:00
|
|
|
require 'capybara/rspec_matchers'
|
2009-11-14 04:44:46 -05:00
|
|
|
|
2009-11-16 16:02:16 -05:00
|
|
|
World(Capybara)
|
2011-02-06 08:44:43 -05:00
|
|
|
World(Capybara::RSpecMatchers)
|
2009-11-16 14:16:12 -05:00
|
|
|
|
|
|
|
After do
|
2009-11-16 16:02:16 -05:00
|
|
|
Capybara.reset_sessions!
|
2009-11-16 14:16:12 -05:00
|
|
|
end
|
|
|
|
|
|
|
|
Before('@javascript') do
|
2009-11-16 16:02:16 -05:00
|
|
|
Capybara.current_driver = Capybara.javascript_driver
|
2009-11-16 14:16:12 -05:00
|
|
|
end
|
|
|
|
|
2009-11-18 17:38:27 -05:00
|
|
|
Before('@selenium') do
|
|
|
|
Capybara.current_driver = :selenium
|
|
|
|
end
|
|
|
|
|
2010-01-01 12:00:04 -05:00
|
|
|
Before('@celerity') do
|
|
|
|
Capybara.current_driver = :celerity
|
|
|
|
end
|
|
|
|
|
2009-11-18 17:38:27 -05:00
|
|
|
Before('@culerity') do
|
|
|
|
Capybara.current_driver = :culerity
|
|
|
|
end
|
|
|
|
|
|
|
|
Before('@rack_test') do
|
|
|
|
Capybara.current_driver = :rack_test
|
|
|
|
end
|
|
|
|
|
|
|
|
After do
|
2009-11-16 16:02:16 -05:00
|
|
|
Capybara.use_default_driver
|
2009-11-21 14:17:07 -05:00
|
|
|
end
|