When using the application Thread.sleep(2000) works well, but on waitForCondition it fails. Is there a better way to use the waitForCondition function? Please provide some examples. Can we give //h1[@class='some'] in waitForCondition ? or waitForCondition work on a specific path?
I used like:
selenium.waitForCondition("selenium.isElementPresent(\"//div[@id='pagging-section']\")","5000");
But it fails. Thread.sleep works well, but I am not recommended to use this method.
Please share with me the correct use of waitForCondition and any other best way to wait and find the item and continue.
source share