1
0
Fork 0
mirror of https://github.com/teamcapybara/capybara.git synced 2022-11-09 12:08:07 -05:00

Leave it up to the driver to make sure that resetting is synchronous

I think that this was a futile attempt to resolve problems with restting sessions which should be much better handled by the addition of `wait_for_pending_requests`.

Closes #1670
This commit is contained in:
Jonas Nicklas 2016-03-30 20:27:29 +02:00 committed by Thomas Walpole
parent 4e23b61041
commit 8d5a7e18ad
4 changed files with 5 additions and 18 deletions

View file

@ -134,8 +134,4 @@ class Capybara::Driver::Base
def needs_server?
false
end
def browser_initialized?
true
end
end

View file

@ -87,10 +87,6 @@ class Capybara::RackTest::Driver < Capybara::Driver::Base
@browser = nil
end
def browser_initialized?
!@browser.nil?
end
def get(*args, &block); browser.get(*args, &block); end
def post(*args, &block); browser.post(*args, &block); end
def put(*args, &block); browser.put(*args, &block); end

View file

@ -248,10 +248,6 @@ class Capybara::Selenium::Driver < Capybara::Driver::Base
Selenium::WebDriver::Error::NoSuchWindowError
end
def browser_initialized?
!@browser.nil?
end
private
def within_given_window(handle)

View file

@ -107,7 +107,6 @@ module Capybara
def reset!
if @touched
driver.reset!
assert_no_selector :xpath, "/html/body/*" if driver.browser_initialized?
@touched = false
end
@server.wait_for_pending_requests if @server