Welcome to OStack Knowledge Sharing Community for programmer and developer-Open, Learning and Share
Welcome To Ask or Share your Answers For Others

Categories

0 votes
782 views
in Technique[技术] by (71.8m points)

selenium - difference between WebDriver Wait timeout and implicitlyWait timeout?

I want to know technical difference between WebDriver Wait timeout and implicitlyWait timeout.

See Question&Answers more detail:os

与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
Welcome To Ask or Share your Answers For Others

1 Answer

0 votes
by (71.8m points)

As said in the documentation:

Implicit Wait sets internally a timeout that will be used for all consecutive WebElement searches. It will try lookup the element again and again for the specified amount of time before throwing an NoSuchElementException if the element could not have been found. It does only this and can't be forced into anything else - it waits for elements to show up.

Explicit Wait, or just Wait is a one-timer used by you for a particular search. It is more extendible in the means that you can set it up to wait for any condition you might like. Usually, you can use some of the prebuilt ExpectedConditions to wait for elements to become clickable, visible, invisible, etc., or just write your own condition that suits your needs.


与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
Welcome to OStack Knowledge Sharing Community for programmer and developer-Open, Learning and Share
Click Here to Ask a Question

...