As stated by the Selenium Documentation we never should mix up explicit and implicit wait times:
WARNING: Do not mix implicit and explicit waits. Doing so can cause unpredictable wait times. For example setting an implicit wait of 10s and an explicit wait of 15 seconds, could cause a timeout to occur after 20 seconds.
I've set a implicit wait time of 5000 ms. At the end of some Browser interaction I just want to verify whether the required links are clickable.
I know that this can be done by using ExpectedConditions
, but this implies an explicit wait time as in the example below.
protected PageNewDocument isElementClickable(WebElement element)
{
(new WebDriverWait(driver, 1)).until(ExpectedConditions.elementToBeClickable(element));
return this;
}
How can I check for elements to be clickable without the definition of an explicit wait time?