-
Notifications
You must be signed in to change notification settings - Fork 3.1k
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
fix: 28187 Include checkVisibility browser API as a reliable tool to check visibility #29741
base: develop
Are you sure you want to change the base?
fix: 28187 Include checkVisibility browser API as a reliable tool to check visibility #29741
Conversation
|
…//github.com/senpl/cypress into issue-28187-IncludeCheckVisibilityBrowserAPI
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@senpl There are some failures in the assertions spec in CI for this change.
…//github.com/senpl/cypress into issue-28187-IncludeCheckVisibilityBrowserAPI
This related to visibility fixed. |
@senpl All of the tests will need to be passing in order for us to merge, with no breaking changes to users. |
…//github.com/senpl/cypress into issue-28187-IncludeCheckVisibilityBrowserAPI
…//github.com/senpl/cypress into issue-28187-IncludeCheckVisibilityBrowserAPI
If visibility should work exactly like in older version this could be done. Still this could be done as option or parameter if really needed. To decide what should be default for new version. Coz right now visible element are marked as not visible and it probably should be warning not error. Because someone might not need interaction, only check if something is visible. |
@senpl The tests are failing in webkit for the visibility spec |
…//github.com/senpl/cypress into issue-28187-IncludeCheckVisibilityBrowserAPI
This test failing in my build with old visibility implementation so I turn them off for webkit as their seems just not compatible with current webkit. To make it work in new version I would need version that works in old version without trackback to very old builds. Also in newer version of webkit their work as well. Just version in build seems not working. |
Visibility check in browser is close to one used in cypress. Still some test has to be changed to make it compatible with what is really seen in browser.
If backward compatibility is required then some option could be applied to make elements previously invisible still detected as invisible. Still default should be compatible with browser implementation.
Include
checkVisibility
browser API as a reliable tool to check visibility #28187Additional details
It should close many other visibility issues,
Steps to test
//this now should work
cy.get('details')
.children('div')
.should('not.be.visible')
How has the user experience changed?
Users should now use is hidden not is visible. Because some element might be visible still not really clicable or interactable.
In old version that two was connected. But hidden is not the same as visible. So this change make it compatible with other frameworks implementation.
PR Tasks
cypress-documentation
?type definitions
?