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

[test] Restore clock between each test #21760

Merged
merged 1 commit into from Jul 12, 2020
Merged

Conversation

eps1lon
Copy link
Member

@eps1lon eps1lon commented Jul 11, 2020

It's important to restore fake timers between tests so that other cleanup tasks can rely on real timers. This is not yet problematic but makes it hard to reason about time with react@next or react@experimental.

In the future we likely expose a complete function that takes care of cleanup. But since we can't hide sinon yet (need yarn v2+test package) I'm sticking with manual cleanup + errors if done incorrectly.

@eps1lon eps1lon added the test label Jul 11, 2020
@mui-pr-bot
Copy link

Details of bundle changes

Generated by 🚫 dangerJS against 70e1719

@eps1lon eps1lon merged commit 3ed80fe into mui:next Jul 12, 2020
@eps1lon eps1lon deleted the test/cleanup-clock branch July 12, 2020 10:19
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

4 participants