-
Notifications
You must be signed in to change notification settings - Fork 28.9k
Randomize tests, exclude tests that fail with randomization. #86793
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
Conversation
This pull request has been changed to a draft. The currently pending flutter-gold status will not be able to resolve until a new commit is pushed or the change is marked ready for review again. For more guidance, visit Writing a golden file test for Reviewers: Read the Tree Hygiene page and make sure this patch meets those guidelines before LGTMing. |
5dccbfe
to
ab1e4b0
Compare
ca69209
to
0d7eb05
Compare
0d7eb05
to
02541ed
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM. Nice work.
String? _shuffleSeed; | ||
String get shuffleSeed { | ||
if (_shuffleSeed == null) { | ||
// Change the seed at 7am, UTC. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Why 7am UTC? Just curious.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It is approximately midnight Pacific, and for the majority of Flutter framework developers will switch sometime between midnight and 9am. I would have made it be midnight Pacific, except that Dart has no way to compute whether it is daylight savings time or not, so it is sometimes 11pm, sometimes midnight. I also didn't want to make it midnight local time, since who knows where our servers will be running the tests in the future, so UTC was a better bet.
Description
This re-lands PR #85159, now that the test package has been published with support for turning off randomization for a particular tag.
This change will cause tests to be run in a random order, determined by a random seed that is set to YYYYMMDD, so that the same test will continue to fail on the same day. The seed changes at 7am UTC. To reproduce the failure, developers can run locally with the same seed as the failure (which is printed in the test logs).
To determine which tests fail with it on, I ran all the tests 100 times with different random shuffle seeds, and then also ran it with the date seeds from today until the end of August, and tagged all of the test suites (files) that fail, with a seed that caused them to fail.
Related Issues
no-shuffle
tags from all framework tests #85160Tests
no-shuffle
tags from all framework tests #85160