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

Minor regression in 2.5+ (Test helpers firing native elements) #13153

Closed
cibernox opened this issue Mar 21, 2016 · 2 comments
Closed

Minor regression in 2.5+ (Test helpers firing native elements) #13153

cibernox opened this issue Mar 21, 2016 · 2 comments

Comments

@cibernox
Copy link
Contributor

I discovered that #12575 (Implemented by me) introduced a subtle change.

After that PR, click(".btn-submit") fires a click event on the first element with that class.
Previously it would trigger a many click, in all elements with that class.

I'd personally found this regression beneficial in my test suite. I caught three tests that where broken because there was more than one link that matched :contains("Save") (probably added after the test was originally written), but it turned out that the assertions after the click weren't specific enough and I was in a totally unexpected route.

I'd say that clicking several items at once is almost always not the intended behaviour and the new behaviour is less error prone, but still this is still a somehow breaking.

@rwjblue
Copy link
Member

rwjblue commented Mar 22, 2016

Thanks for opening this to get it out in the open. The current behavior (clicking the first item) seems more correct to me, and the old behavior seems more like a bug.

Acceptance tests are intended to emulate user behavior, and it generally isn't possible for a user to click in many different places at once (no matter how quick the user clicks were they would be separated by at least a millisecond)...

@cibernox
Copy link
Contributor Author

Good, I also think this changes is for the better.

I'm closing this so people with this problem can find a reference to why their test suite is failing and how to fix it.

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

2 participants