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] Correctly identify what the raf helper is for #29683

Merged
merged 1 commit into from
Nov 15, 2021

Conversation

eps1lon
Copy link
Member

@eps1lon eps1lon commented Nov 15, 2021

The requestAnimationFrame may have been important in earlier implementations for @popperjs/core. But now @popperjs/core only relies on microtasks for batching state updates.

So let's just flush the state update (wrapped in act). This significantly simplifies the test since we use less helpers and can re-use the same (fake) clock as the other tests in this suite.

React 17 browser run: https://app.circleci.com/pipelines/github/mui-org/material-ui/56264/workflows/8a04eba7-a91c-4dc3-b477-35df19bfe3f5
React 18 browser run (failures are unrelated): https://app.circleci.com/pipelines/github/mui-org/material-ui/56266/workflows/8e18b4b2-0da2-48da-90f2-45c26c85cc2a

@eps1lon eps1lon added the test label Nov 15, 2021
@mui-pr-bot
Copy link

mui-pr-bot commented Nov 15, 2021

No bundle size changes

Generated by 🚫 dangerJS against 935999f

@eps1lon eps1lon marked this pull request as ready for review November 15, 2021 11:26
@eps1lon eps1lon merged commit 08f37a7 into mui:master Nov 15, 2021
@eps1lon eps1lon deleted the test/tooltip-raf branch November 15, 2021 11:26
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.

2 participants