Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

🐛 Increase timeout to 1.5x the asset discovery timeout (30s) #380

Merged
merged 1 commit into from
Jul 22, 2021

Conversation

Robdel12
Copy link
Contributor

What is this?

Assets that take a long time to respond in asset discovery can cause the cy.then promise to timeout. We must wait for all assets to be discovered/resolved/captured before moving onto the next test, or we risk capturing the wrong asset for that given snapshot. For example, if the server shuts down after each test, we would fail to capture those assets if we didn't await on asset discovery to finish (resulting in broken snapshots).

With that said, we can safely increase this timeout beyond asset discoveries timeout since asset discovery will timeout first.

Assets that take a long time to respond in asset discovery can cause the
`cy.then` promise to timeout. We _must_ wait for all assets to be
discovered/resolved/captured before moving onto the next test, or we risk
capturing the wrong asset for that given snapshot. For example, if the server
shuts down after each test, we would fail to capture those assets if we didn't
await on asset discovery to finish.

With that said, we can safely increase this timeout beyond asset discoveries
timeout since asset discovery will timeout first.
@Robdel12 Robdel12 requested a review from wwilsman July 22, 2021 18:23
@Robdel12 Robdel12 added the 🐛 bug Something isn't working label Jul 22, 2021
Copy link
Contributor

@wwilsman wwilsman left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🎮

@Robdel12 Robdel12 merged commit dc2face into master Jul 22, 2021
@Robdel12 Robdel12 deleted the rd/increase-timeout-for-asset-discovery branch July 22, 2021 18:30
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
🐛 bug Something isn't working
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants