0
votes

I need help on wait function in Selenium webdriver.
I have the following code to wait for "Progressing Pop up" to disappear. It seems it waits only for some seconds and terminates the script. Please let me know what are the other option?

public static void ProcessingData() throws Exception {
    WebDriverWait wait1 = new WebDriverWait( driver , 180 ); 


    wait1.until(ExpectedConditions.invisibilityOfElementLocated(By.xpath("//div[@class='dijitDialogPaneContent']/div/p/b[contains(text()='Processing ...']")));
}
2
If one of the answers was the solution to your problem, please mark this as complete! :) - ddavison
None of these answers are solution for this problem. - tester
if none of the answers below solve your problem, could you show the html? this could help us. - ddavison

2 Answers

1
votes

You placed your timeout on 180, which is 180 milliseconds. You probably mean 180 seconds? So use 180000.

1
votes

I'd take a closer look at your xpath selector... you are providing

...b[contains(text()='Processing ...']

If you know that the text is equal to processing, then you should use

...b[text()='Processing ...'].

If you know that the text CONTAINS Processing ... then you should use,

...b[contains(text(), 'Processing ...']