What is that expectedcondition which is used "internally" by Implicit wait?

61 views Asked by At

Within the set max time limit, Implicit wait waits till it finds the element(unlike Thread. sleep(), it does not wait for the complete duration of time), explicit wait waits until it meets the declared expectedcondition. For Explicit wait we have different expectedconditions which we declare explicitly similarly what is that expectedcondition which is used internally by Implicit wait to find an element?

1

There are 1 answers

1
undetected Selenium On

Implicit Wait doesn't uses any ExpectedConditions per se.


Implicit Wait

Implicit Wait directs the WebDriver to wait for a certain amount of time before throwing an exception. Once this time is set, WebDriver will wait for the element before the exception occurs.

Once you configure, Implicit Wait stays in place for the entire duration for which the browser is open. The default setting is 0, and the specific wait time needs to be set by the following protocol.

import java.util.concurrent.TimeUnit;

driver.manage().timeouts().implicitlyWait(10, TimeUnit.SECONDS);