My two scenarios -
1) First
@driver.manage.timeouts.implicit_wait = 30
@wait = Selenium::WebDriver::Wait.new(:timeout => 45) # Time greater than implicit
@wait.until {@driver.find_element(:tag_name => "body").text.include?("hey")}
Which gives the driver 45 seconds to search for the text(which is expected)
2) Second
@driver.manage.timeouts.implicit_wait = 30
@wait = Selenium::WebDriver::Wait.new(:timeout => 5) # Time less than implicit
@wait.until {@driver.find_element(:tag_name => "body").text.include?("hey")}
This now gives the driver 30 seconds to search for the text(not expected)
Is there a way to make selenium wait only for the explicit wait time and not for the greater of the two?
Note - Not declaring the implicit wait time is not an option, cause I cannot afford to let selenium hang each time the driver is unable to find something.
Using Selenium version 30, windows, ff
The default setting is 0according to the implicit wait docs, so what exactly is the problem here?