raise error if window size isn't stable within wait time

This commit is contained in:
Thomas Walpole 2017-11-19 10:10:15 -08:00
parent d873b83b2a
commit c405ce5dc6
1 changed files with 1 additions and 4 deletions

View File

@ -125,10 +125,7 @@ module Capybara
return res if cur_size == prev_size
prev_size = cur_size
end while (Capybara::Helpers.monotonic_time - start_time) < seconds
#TODO raise error in 3.0
#raise Capybara::WindowError, "Window size not stable."
warn "Window size not stable in #{seconds} seconds. This will raise an exception in a future version of Capybara"
return res
raise Capybara::WindowError, "Window size not stable within #{seconds} seconds."
end
def raise_unless_current(what)