I am writing Test Cases using Selenium web Driver.
I need to setup implicit wait for Chrome driver. I don't need explicit-it is too long!
Is there any way to force Google Chrome driver throw a TimeOutException
or (refresh page would also work) after 5 seconds of its attempt to upload a page.
I tried: driver.manage().timeouts().implicitlyWait(5, TimeUnit.SECONDS);
It does not work. Here is the brief source code:
.......
driver.manage().timeouts().implicitlyWait(5, TimeUnit.SECONDS);
.......
.......
element.click();
.......
Now I need the driver to throw a TimeOutException
if the page does not load within 5 seconds.