mirror of
https://github.com/teamcapybara/capybara.git
synced 2022-11-09 12:08:07 -05:00
Added configure method to Capybara module
This commit is contained in:
parent
d05cf9b9ec
commit
dbfb3ee0e0
2 changed files with 7 additions and 1 deletions
|
@ -24,6 +24,10 @@ module Capybara
|
||||||
def default_wait_time
|
def default_wait_time
|
||||||
@default_wait_time ||= 2
|
@default_wait_time ||= 2
|
||||||
end
|
end
|
||||||
|
|
||||||
|
def configure
|
||||||
|
yield self
|
||||||
|
end
|
||||||
end
|
end
|
||||||
|
|
||||||
autoload :Server, 'capybara/server'
|
autoload :Server, 'capybara/server'
|
||||||
|
|
|
@ -14,6 +14,8 @@ Capybara.default_wait_time = 0 # less timeout so tests run faster
|
||||||
|
|
||||||
Spec::Runner.configure do |config|
|
Spec::Runner.configure do |config|
|
||||||
config.before do
|
config.before do
|
||||||
Capybara.default_selector = :xpath
|
Capybara.configure do |config|
|
||||||
|
config.default_selector = :xpath
|
||||||
|
end
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue