0

I would like to find out how to make waiter for assertion with window title text in selenide / selenium

something like this:

waitUntil(assertion.true(Selenide.title().toLowerCase().startsWith("text")), timeout);

may be you could help me?

gore
  • 551
  • 2
  • 20

1 Answers1

0

Solved like this:

{ ...
     await().atMost(timeOut, SECONDS).until(assertionWaitForTitle("text")); 
}

private Callable<Boolean> assertionWaitForTitle(String start) {
     return () -> Selenide.title().toLowerCase().startsWith(start);
}
gore
  • 551
  • 2
  • 20