Cypress commands should not be invoked in a loop as it is an anti-pattern
that can produce flaky tests.
Details
Details
- Reviewers
ardumont - Group Reviewers
Reviewers - Commits
- rDWAPPSa9688b3a9818: cypress/layout: Fix cypress anti-pattern use
Diff Detail
Diff Detail
- Repository
- rDWAPPS Web applications
- Lint
Automatic diff as part of commit; lint not applicable. - Unit
Automatic diff as part of commit; unit tests not applicable.
Event Timeline
Comment Actions
Build is green
Patch application report for D5982 (id=21563)
Rebasing onto 25c639f292...
Current branch diff-target is up to date.
Changes applied before test
commit a9688b3a981847d71c56e340c25f743c94a8d85a Author: Antoine Lambert <anlambert@softwareheritage.org> Date: Thu Jul 8 19:08:14 2021 +0200 cypress/layout: Fix cypress anti-pattern use Cypress commands should not be invoked in a loop as it is an anti-pattern that can produce flaky tests.
See https://jenkins.softwareheritage.org/job/DWAPPS/job/tests-on-diff/957/ for more details.
Comment Actions
lgtm
cypress/integration/layout.spec.js | ||
---|---|---|
185 | I guess those calls could have been made in a loop though, right? (just asking out of curiosity, not asking you to change anything ;) |
cypress/integration/layout.spec.js | ||
---|---|---|
185 | The thing is that we can't use for loops with cypress because of its async nature. |
cypress/integration/layout.spec.js | ||
---|---|---|
185 | ah yes, thx! |