Package org.jvnet.hudson.test
Class QueryUtils
java.lang.Object
org.jvnet.hudson.test.QueryUtils
-
Method Summary
Modifier and TypeMethodDescriptionstatic org.htmlunit.html.HtmlElement
waitUntilElementIsPresent
(org.htmlunit.html.HtmlPage page, String query) Waits until the given query selector is visible on the page, otherwise returns nullstatic void
waitUntilStringIsNotPresent
(org.htmlunit.html.HtmlPage page, String value) Waits until the given string is not visible on the page, otherwise throws an exceptionstatic void
waitUntilStringIsPresent
(org.htmlunit.html.HtmlPage page, String value) Waits until the given string is visible on the page, otherwise throws an exception
-
Method Details
-
waitUntilStringIsPresent
Waits until the given string is visible on the page, otherwise throws an exception- Parameters:
page
- the pagevalue
- the value to find- Throws:
RuntimeException
- if string is not present after three seconds
-
waitUntilStringIsNotPresent
Waits until the given string is not visible on the page, otherwise throws an exception- Parameters:
page
- the pagevalue
- the value to not find- Throws:
RuntimeException
- if string is present after three seconds
-
waitUntilElementIsPresent
public static org.htmlunit.html.HtmlElement waitUntilElementIsPresent(org.htmlunit.html.HtmlPage page, String query) Waits until the given query selector is visible on the page, otherwise returns null- Parameters:
page
- the pagequery
- the query selector for the element
-