-2

If I use thread-sleep wait then It is being disable easy but I can't thread wait so which wait is alternate of thread-sleep to being disable and validate it?

Prophet
  • 32,350
  • 22
  • 54
  • 79
  • With any question asked, you should include the relevant HTML, an [mcve], and the error message or a description of what isn't working as expected. Please edit this question and add those details so we can provide useful answers. – JeffC Aug 29 '22 at 14:44

1 Answers1

0

You can do that with the use of WebDriverWait ExpectedConditions.
With them you can define the timeout - how long to wait for the expected condition and the condition itself. In your case you probably would like to wait for class or some other attribute to appear or disappear.
All these and much more are covered by WebDriverWait ExpectedConditions.
You can learn more about this here, here and much more other documentations available on the Internet.

Prophet
  • 32,350
  • 22
  • 54
  • 79