Thursday 26 November 2020

Cypress Angular When Can Test Start?

I'm using Cypress to do end-to-end testing on my Angular application. One source of flake that I have observed is that Cypress is fast to act and my application is (relatively) slow to become ready for interaction. Cypress has some oft-referenced blog posts that discuss this quandary.

The example in one of the blog posts suggests hijacking the addEventListener to handle a very specific example. But what I am looking for is the appropriate "sledgehammer" for Angular... anyone have any bright ideas / techniques that don't involve adding a 10 second wait to every page visit before engaging test activity (which by the way does work)? I have spent considerable time Googling to no avail. Thanks in advance for your ideas!

Aside: I've also found this open issue that, were it to be resolved fruitfully might be part of the answer.



from Cypress Angular When Can Test Start?

No comments:

Post a Comment