You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I made a silly mistake today that stumped me for too long. When writing my intercept tests I passed the callback as a second parameter to wait, instead of using a then:
// WRONG:cy.wait('@request',(interception)=>{// do stuff})// RIGHT:cy.wait('@request').then((interception)=>{// do stuff})
Obviously this was totally my mistake, but it seems like something that could have an error message for morons like me?
Why is this needed?
No response
Other
No response
The text was updated successfully, but these errors were encountered:
This wouldn't be too hard to implement. Detect that the second argument passed to cy.wait() is a function and throw an error explaining that the 2nd argument is meant to be an options object. We do this in our other commands. We'd be open to a PR.
What would you like?
I made a silly mistake today that stumped me for too long. When writing my intercept tests I passed the callback as a second parameter to
wait
, instead of using athen
:Obviously this was totally my mistake, but it seems like something that could have an error message for morons like me?
Why is this needed?
No response
Other
No response
The text was updated successfully, but these errors were encountered: