Skip to content

Instantly share code, notes, and snippets.

Embed
What would you like to do?
generated automatically from #selenium on seleniumhq slack
public static ExpectedCondition<Boolean> elementNotPresent(By selector) {
return new ExpectedCondition<Boolean>() {
@Override
public Boolean apply(WebDriver driver) {
return driver.findElements(selector).size() == 0;
}
@Override
public String toString() {
return selector.toString() + " to disappear";
}
};
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.