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
|
||||
@default_wait_time ||= 2
|
||||
end
|
||||
|
||||
def configure
|
||||
yield self
|
||||
end
|
||||
end
|
||||
|
||||
autoload :Server, 'capybara/server'
|
||||
|
|
|
@ -14,6 +14,8 @@ Capybara.default_wait_time = 0 # less timeout so tests run faster
|
|||
|
||||
Spec::Runner.configure do |config|
|
||||
config.before do
|
||||
Capybara.default_selector = :xpath
|
||||
Capybara.configure do |config|
|
||||
config.default_selector = :xpath
|
||||
end
|
||||
end
|
||||
end
|
||||
|
|
Loading…
Reference in a new issue