Created
January 29, 2020 19:47
-
-
Save brobles82/59bc19a65180643d9fa131830624c084 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
public static void click(WebElement webElement) { | |
WebDriverWait wait = new WebDriverWait(driver(), 30); | |
ExpectedCondition<Boolean> elementIsClickable = arg0 -> { | |
try { | |
webElement.click(); | |
return true; | |
} catch (Exception e) { | |
return false; | |
} | |
}; | |
wait.until(elementIsClickable); | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment