Namespace: untilUrlMatches

untilUrlMatches

untilUrlMatches(driver, regex, timeopt)

untilUrlMatches

Parameters:
Name Type Attributes Description
driver Object

webdriver object of web browser.

regex String

Regular Expression of url.

time Number <optional>

time parameter is optional & it represents for how much time user want to wait for "url". After time finish it stops operation & return error.

Example

Examples usage of untilUrlMatches

 untilUrlMatches(driver, /^example$/, time).then((webElement) => {
   //In this methiod we paas the regex for the url.
   // It will wait until url is not matched with regex.
 }).catch((error) => {
   // handle error
 });