seek-oss / playroom

Design with JSX, powered by your own component library.
MIT License
4.45k stars 183 forks source link

Remove cypress delays, modify assertions to leverage cypress' retryability #328

Closed askoufis closed 4 months ago

askoufis commented 4 months ago

Converting some of thens into shoulds and utilizing its lets us lean into cypress' retry mechanisms, so we don't need to wait for iframe loads or add tons of delays during interactions anymore.

This blog post came in handy for the iframe stuff: https://www.cypress.io/blog/2020/02/12/working-with-iframes-in-cypress

The only exception is the autocompletes test as that relies on the autocomplete options to have rendered before the enter key is pressed.

Also bumped cypress to v13. Would be good to run CI a few times to confirm that it's stable enough for our liking.

changeset-bot[bot] commented 4 months ago

⚠️ No Changeset found

Latest commit: 1df49ea68741866d8bba4cfec64b540d7fa89126

Merging this PR will not cause a version bump for any packages. If these changes should not result in a new version, you're good to go. If these changes should result in a version bump, you need to add a changeset.

This PR includes no changesets When changesets are added to this PR, you'll see the packages that this PR includes changesets for and the associated semver types

Click here to learn what changesets are, and how to add one.

Click here if you're a maintainer who wants to add a changeset to this PR