Test gets into runaway loop if cy.wrap is inside cy.should
See original GitHub issueCypress v6.3.0
it('gets into a loop', () => {
cy.wrap('bar')
.should(() => {
cy.wrap('foo')
})
})
Runs away, never finishes
https://user-images.githubusercontent.com/2212006/105213850-39648400-5b1d-11eb-92fe-0d04751496e6.mp4
Example in https://github.com/cypress-io/cypress-test-tiny/tree/runaway
Issue Analytics
- State:
- Created 3 years ago
- Reactions:6
- Comments:9 (4 by maintainers)
Top Results From Across the Web
wrap - Cypress Documentation
cy.wrap() , when its argument is a promise, will automatically wait until the promise resolves. If the promise is rejected, cy.wrap() will fail...
Read more >A Better cy.each Iteration - Gleb Bahmutov
We need a way to avoid queuing unnecessary commands. To do this, we can queue cy. then(callback) inside the each(callback) . Inside the...
Read more >Where do we use cy.wrap() command in Cypress Test - Medium
I try to find the element of the email input field using the cy.get() command, this cy.get() command will yield us an element....
Read more >Cypress IO- Writing a For Loop - Stack Overflow
While cy.wrap().each() will work (one of the answers given for this question), I wanted to give an alternate way that worked for me....
Read more >Wlj - River Thames Conditions - Environment Agency - GOV.UK
Programme 25 minutes workout, Surf and save turtles in costa rica. ... of trying to be perfect, Optative sentences worksheets, Niagara falls skywheel...
Read more >
Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free
Top Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Just randomly hit this again, ughh, and aside from this I do see runaway tests sometimes, but larger ones, seems there might be edge cases in the internal logic
https://user-images.githubusercontent.com/2212006/140448613-37acd0d6-3106-4977-8559-f9f2dc4ddbe9.mp4
Super