Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

SeleniumExtras.WaitHelpers.ExpectedConditions.ElementToBeClickable(IWebelement element) method will encounter a bug if there is a cover layer of loading over the element #14

Open
EZevan opened this issue Mar 6, 2020 · 0 comments

Comments

@EZevan
Copy link

EZevan commented Mar 6, 2020

Hi, just as title described,It is seems that if there is a cover layer of loading over the element(this element will be enabled and displayed at this time),the ElementToBeClickable method will throw a specified element cannot be clicked exception.

Append the source code about above method:
public static Func<IWebDriver, IWebElement> ElementToBeClickable( IWebElement element) { return (Func<IWebDriver, IWebElement>) (driver => { try { if (element != null && element.Displayed && element.Enabled) return element; return (IWebElement) null; } catch (StaleElementReferenceException ex) { return (IWebElement) null; } }); }

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant