How to use watir-webdriver to wait for page load

后端 未结 7 1877
后悔当初
后悔当初 2021-02-01 21:34

Using watir-webdriver, how do I wait for a page to load after I click a link?

At the moment I am using:

sleep n

But this is not ideal a

7条回答
  •  囚心锁ツ
    2021-02-01 22:26

    Today's release adds an optional require that brings in some helpers for waiting for elements. These are not (at the moment) available in Watir 1.6, so be aware if you use both libraries side by side.

    Check "AJAX and waiting for elements" in the Watir-webdriver Wiki for more information.

提交回复
热议问题