How to deal with fast actions #16019
-
I have a table showing the results of a query.
Sometimes this code fails on the first line because the loading is so fast Cypress can't catch the visibility of the loading spinner. Worst of all, this scenario is making my test results depending on the server load. I could wait for the raw server response, but that wouldn't be practical and maybe not even possible, I have dozens of tables querying different endpoints, sometimes more than one for the same table. |
Beta Was this translation helpful? Give feedback.
Replies: 1 comment
-
Take a look at https://docs.cypress.io/guides/references/assertions#Negative-assertions and at https://glebbahmutov.com/blog/negative-assertions/ I would spy on the query API call and delay it to test the loading spinner in action. |
Beta Was this translation helpful? Give feedback.
Take a look at https://docs.cypress.io/guides/references/assertions#Negative-assertions and at https://glebbahmutov.com/blog/negative-assertions/
I would spy on the query API call and delay it to test the loading spinner in action.