Wait in Selenium Implicit,Explicit ,Fluent ,Thread.sleep


Wait in selenium-
1)implicit wait

Syntax-for implicit wait
_________________________________________________________________________________
driver.manage().timeouts().implicitlyWait(TimeOut, TimeUnit.SECONDS);
_________________________________________________________________________________

2)Explicit Wait

Syntax-for Explicit Wat
_________________________________________________________________________________
WebDriverWait wait = new WebDriverWait(WebDriverRefrence,TimeOut);
_________________________________________________________________________________

3)Fluent wait

Syntax- for fluent Wait
_________________________________________________________________________________
Wait wait = new FluentWait(WebDriver reference)
.withTimeout(timeout, SECONDS)
.pollingEvery(timeout, SECONDS)
.ignoring(Exception.class);
_________________________________________________________________________________

4)Thread.sleep
Syntax-for thread.sleep
_________________________________________________________________________________
Thread.sleep(5000);
____________________________________________________________