mirror of
https://github.com/teamcapybara/capybara.git
synced 2022-11-09 12:08:07 -05:00
aa46894ce7
Just the basics of including Capybara and setting up some metadata to switch between drivers.
14 lines
378 B
Ruby
14 lines
378 B
Ruby
require 'capybara'
|
|
require 'capybara/dsl'
|
|
|
|
Rspec.configure do |config|
|
|
config.include Capybara
|
|
config.after do
|
|
Capybara.reset_sessions!
|
|
Capybara.use_default_driver
|
|
end
|
|
config.before do
|
|
Capybara.current_driver = Capybara.javascript_driver if example.metadata[:js]
|
|
Capybara.current_driver = example.metadata[:driver] if example.metadata[:driver]
|
|
end
|
|
end
|