[flutter_tools] add shuffle to hermetic run_tests#105462
Merged
fluttergithubbot merged 5 commits intoflutter:masterfrom Jun 9, 2022
Merged
[flutter_tools] add shuffle to hermetic run_tests#105462fluttergithubbot merged 5 commits intoflutter:masterfrom
fluttergithubbot merged 5 commits intoflutter:masterfrom
Conversation
| TestUsageCommand('run', parameters: CustomDimensions.fromMap(<String, String>{ | ||
| 'cd3': 'false', 'cd4': 'ios', 'cd22': 'iOS 13', | ||
| 'cd23': 'debug', 'cd18': 'false', 'cd15': 'swift', 'cd31': 'false', | ||
| 'cd23': 'debug', 'cd18': 'false', 'cd15': 'swift', 'cd31': 'true', |
Contributor
Author
There was a problem hiding this comment.
cd31 is commandHasTerminal (https://github.com/christopherfujino/flutter/blob/improve-run-test/packages/flutter_tools/lib/src/reporting/custom_dimensions.dart#L102). The global environment was leaking into this test previously; thus, this test was passing on CI, since the Dart VM did not have a terminal attached, yet failing locally since it did. By overriding the context with a FakeStdio that defaults to hasTerminal = true, this dimension should be true both locally and on CI.
| final MemoryStdout _stdout = MemoryStdout()..terminalColumns = 80; | ||
| final MemoryIOSink _stderr = MemoryIOSink(); | ||
| final StreamController<List<int>> _stdin = StreamController<List<int>>(); | ||
| final FakeStdin _stdin = FakeStdin(); |
Contributor
Author
There was a problem hiding this comment.
Previously this was failing the cast in https://github.com/christopherfujino/flutter/blob/improve-run-test/packages/flutter_tools/lib/src/base/terminal.dart#L286.
This was referenced Jun 10, 2022
engine-flutter-autoroll
added a commit
to engine-flutter-autoroll/packages
that referenced
this pull request
Jun 10, 2022
engine-flutter-autoroll
added a commit
to engine-flutter-autoroll/plugins
that referenced
this pull request
Jun 10, 2022
engine-flutter-autoroll
added a commit
to engine-flutter-autoroll/packages
that referenced
this pull request
Jun 10, 2022
engine-flutter-autoroll
added a commit
to engine-flutter-autoroll/plugins
that referenced
this pull request
Jun 10, 2022
engine-flutter-autoroll
added a commit
to engine-flutter-autoroll/packages
that referenced
this pull request
Jun 10, 2022
engine-flutter-autoroll
added a commit
to engine-flutter-autoroll/plugins
that referenced
this pull request
Jun 10, 2022
engine-flutter-autoroll
added a commit
to engine-flutter-autoroll/plugins
that referenced
this pull request
Jun 10, 2022
engine-flutter-autoroll
added a commit
to engine-flutter-autoroll/packages
that referenced
this pull request
Jun 10, 2022
engine-flutter-autoroll
added a commit
to engine-flutter-autoroll/packages
that referenced
this pull request
Jun 10, 2022
This was referenced Jun 11, 2022
engine-flutter-autoroll
added a commit
to engine-flutter-autoroll/packages
that referenced
this pull request
Jun 11, 2022
engine-flutter-autoroll
added a commit
to engine-flutter-autoroll/plugins
that referenced
this pull request
Jun 11, 2022
engine-flutter-autoroll
added a commit
to engine-flutter-autoroll/packages
that referenced
this pull request
Jun 11, 2022
engine-flutter-autoroll
added a commit
to engine-flutter-autoroll/packages
that referenced
this pull request
Jun 12, 2022
engine-flutter-autoroll
added a commit
to engine-flutter-autoroll/packages
that referenced
this pull request
Jun 12, 2022
engine-flutter-autoroll
added a commit
to engine-flutter-autoroll/packages
that referenced
this pull request
Jun 13, 2022
engine-flutter-autoroll
added a commit
to engine-flutter-autoroll/packages
that referenced
this pull request
Jun 13, 2022
engine-flutter-autoroll
added a commit
to engine-flutter-autoroll/packages
that referenced
this pull request
Jun 14, 2022
engine-flutter-autoroll
added a commit
to engine-flutter-autoroll/packages
that referenced
this pull request
Jun 14, 2022
engine-flutter-autoroll
added a commit
to engine-flutter-autoroll/packages
that referenced
this pull request
Jun 14, 2022
camsim99
pushed a commit
to camsim99/flutter
that referenced
this pull request
Aug 10, 2022
engine-flutter-autoroll
added a commit
to engine-flutter-autoroll/packages
that referenced
this pull request
Aug 30, 2022
engine-flutter-autoroll
added a commit
to engine-flutter-autoroll/plugins
that referenced
this pull request
Aug 30, 2022
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Part of #85160
Note, the fix to allowing shuffle was actually lifting Cache.disableLocking() to the top level scope in https://github.com/flutter/flutter/pull/105283/files#diff-38f3e3415d9806f22a78060fafb3206d1a006f74631fac04e7a680a64e06ccf0R52, however, I didn't actually disable shuffle in that PR because many other tests in that file were failing locally. The code changes in this PR are just to remove the local terminal from the test code, so that the tests are more hermetic (and all pass for me locally now).