-
Notifications
You must be signed in to change notification settings - Fork 22
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
(DomActions) WTR tests for elementVisible() #497
(DomActions) WTR tests for elementVisible() #497
Conversation
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.
This test is quite repetitive and I was considering some kind of matrix approach, but ultimately didn't do it as it seems to me the test cases are so short and concise, the maintainability might actually suffer if we try to DRY it. Let me know what you think 🙏
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.
I don't mind either way. You could also reuse the same domActions
instance across multiple tests, then the tests would be basically one-liners.
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.
uuu nice, I quite like that! The one-liners are pretty elegant 🚀 👏
1d398f7
to
9b1d328
Compare
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.
I don't mind either way. You could also reuse the same domActions
instance across multiple tests, then the tests would be basically one-liners.
}); | ||
</script> | ||
<div id="none-visible"> | ||
<button style="display:none">This one is invisible</button> |
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.
Could you also add a case when a button element is not hidden itself, but its parent is?
<div style="display:none">
<button>I am hidden too</button>
</div>
There are many more possible cases, but these are probably most common.
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.
Do you mean add it as simply as this 23b3368?
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.
LGTM! thanks again!
No description provided.