Chris Marisic
Chris Marisic

Reputation: 33118

Selenium WebDriver does it understand page loads now?

With the current form of Selenium WebDriver does it understand page loads now?

In my recent research comparing WatiN vs Selenium vs X one of the biggest points I've seen in favor of WatiN was that it understands the concept of a page is loaded, whereas atleast on older versions of Selenium you had to fake this using waits/thread sleeps etc.

Is this now no longer a valid negative against Selenium?

Upvotes: 0

Views: 436

Answers (1)

prestomanifesto
prestomanifesto

Reputation: 12806

Yes, many of the functions in Selenium WebDriver return only after the page has loaded. In other words, many of the old -action-andwait functions have just become -action-.

Looking at the documentation can tell you exactly which functions block and which don't wait for the page to load. For example, here is a snippet of the click function description:

Click this element. If this causes a new page to load, this method will block until the page has loaded.

Upvotes: 2

Related Questions