-
Notifications
You must be signed in to change notification settings - Fork 123
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
isVisible triggers on opacity 0 #418
Comments
The current implementation of
I can see definite utility in altering |
the problem is that there are soooo many ways to make an element invisible that it's not really viable to support all of them. it's correct that the current implementation is based on the jQuery implementation, but apparently that is not quite sufficient. I'm open to adjusting the logic, but that would most likely have to be a breaking change then. |
We could also consider having options to
|
Just stumbled upon this. I was also expected
Tbh, that definition of visibility totally contradicts my "common sense" understanding of what visible is! If a button consumes space, but I cannot see it nor read its text, I would certainly not consider it visible! 😆 I did however remember that Selenium/Webdriver based solutions handle visibility in a IMHO smarter way. Quick google found this: https://github.com/thefrontside/element-is-visible. Maybe we can defer the decision what visible means to this (quite elaborate) util, which seems to mimic the Selenium semantics!? |
I have just been bitten by this as well ( My 2c; I think that the current implementation of isVisible() / isNotVisible() is very misleading, no matter how good the docs are, and definitely leads to invalid tests being written where isVisible() will always succeed, especially in applications that do not use jquery. If not implemented to cover the obvious scenarios (opacity & visiblity styles), then it should probably be removed or at least deprecated.. force the dev to check visibility with other assertion methods like hasClass. |
The current isVisible considers elements with
opacity: 0
to be visible.This seems wrong.
The text was updated successfully, but these errors were encountered: