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] Revert to using fireEvent instead of userEvent #14927

Merged
merged 7 commits into from
Oct 17, 2024

Conversation

LukasTy
Copy link
Member

@LukasTy LukasTy commented Oct 11, 2024

Revert changes introduced in #14142 in an effort to avoid leaking configuration and flakily failing tests.

There were no flaky test_unit failures on this branch. 👌

@LukasTy LukasTy added test component: pickers This is the name of the generic UI component, not the React module! labels Oct 11, 2024
@LukasTy LukasTy self-assigned this Oct 11, 2024
@mui-bot
Copy link

mui-bot commented Oct 11, 2024

Deploy preview: https://deploy-preview-14927--material-ui-x.netlify.app/

Generated by 🚫 dangerJS against 8350551

@LukasTy LukasTy marked this pull request as ready for review October 11, 2024 15:35
@LukasTy LukasTy requested review from cherniavskii and a team October 11, 2024 15:54
@cherniavskii
Copy link
Member

Why revert these changes though?

@LukasTy
Copy link
Member Author

LukasTy commented Oct 14, 2024

Why revert these changes though?

@cherniavskii because the amount of flaky Picker test failures has been too intense lately.
It seems that they started after introducing more async tests to Pickers.

I have tried moving most of the Pickers tests to async in #14583 and it caused way more flaky failures. 🙈

It seems that we can not reliably mix async and sync tests while we are on mocha because it has trouble isolating test contexts. 🤷

@LukasTy LukasTy requested a review from a team October 14, 2024 10:09
@LukasTy
Copy link
Member Author

LukasTy commented Oct 14, 2024

However, for some reason, I haven't seen test:unit fail flakily in the past 10 master merges.

How has it been in everyone's branches? 🤔

@LukasTy LukasTy marked this pull request as draft October 14, 2024 11:13
@LukasTy
Copy link
Member Author

LukasTy commented Oct 14, 2024

I've converted the PR to a draft until we see a new flaky test:unit pipeline failure.

@LukasTy
Copy link
Member Author

LukasTy commented Oct 14, 2024

Here we go again... 🙈
https://app.circleci.com/pipelines/github/mui/mui-x/68873/workflows/1691361d-2eee-491a-b2e5-a84c73131ae5/jobs/392537
So, the flakiness is not gone, it's just varied. 😆

@cherniavskii
Copy link
Member

@LukasTy Do you think we can have the material-ui-v6 workflow passing in this PR?

@LukasTy
Copy link
Member Author

LukasTy commented Oct 16, 2024

Do you think we can have the material-ui-v6 workflow passing in this PR?

This (7a66b0e) seemed to do the trick.
At least locally. 👌

'@mui/material@6.x',
'@mui/system@6.x',
'@mui/icons-material@6.x',
'@mui/utils@6.x',
Copy link
Member Author

Choose a reason for hiding this comment

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

I have added the @mui/utils bump to make it more correct. 🤔
I feel like after #14867 it makes sense. 🤷

@LukasTy LukasTy marked this pull request as ready for review October 16, 2024 14:35
@LukasTy
Copy link
Member Author

LukasTy commented Oct 17, 2024

The PR is ready for review.
Hopefully, it stabilizes the test_unit CI step. 🤞

Copy link
Member

@cherniavskii cherniavskii left a comment

Choose a reason for hiding this comment

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

Looks good! 💙

@cherniavskii cherniavskii merged commit 6a5545e into mui:master Oct 17, 2024
23 checks passed
@LukasTy LukasTy deleted the revert-usage-of-user-event branch October 17, 2024 18:23
@cherniavskii
Copy link
Member

Some tests are still flaky on the master branch: b3700ae
Not sure it's worth so spend much time on trying to fix them at this point.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
component: pickers This is the name of the generic UI component, not the React module! test
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants