0

I got No Such Element Exception just right the moment when the code line is in focus.

new Fluentwait<>(driver)
    .withTimeout(Duration.ofSeconds(30))
    .pollingEvery(Duration.ofSeconds(3))
    .ignoring(org.openqa.selenium.NoSuchElementException.class)
    .until(driver -> driver.findElement(By.id("id")));

Why it ignores the "ignoring" part? It happens only in 1 case, in case of all other webelements it wait, do polling, founf the element within timeout range. In this case it fails at the very moment when it starts.

vinsce
  • 1,271
  • 1
  • 10
  • 19

0 Answers0