Unverified Commit e10049b2 authored by Polina Cherkasova's avatar Polina Cherkasova Committed by GitHub

Turn off randomization for leak detection bots. (#145624)

parent 33739617
...@@ -5237,7 +5237,8 @@ targets: ...@@ -5237,7 +5237,8 @@ targets:
["framework", "hostonly", "shard", "windows"] ["framework", "hostonly", "shard", "windows"]
env_variables: >- env_variables: >-
{ {
"LEAK_TRACKING": "true" "LEAK_TRACKING": "true",
"TEST_RANDOMIZATION_OFF": "true"
} }
runIf: runIf:
- dev/** - dev/**
...@@ -5323,7 +5324,8 @@ targets: ...@@ -5323,7 +5324,8 @@ targets:
["framework", "hostonly", "shard", "windows"] ["framework", "hostonly", "shard", "windows"]
env_variables: >- env_variables: >-
{ {
"LEAK_TRACKING": "true" "LEAK_TRACKING": "true",
"TEST_RANDOMIZATION_OFF": "true"
} }
runIf: runIf:
- dev/** - dev/**
......
...@@ -187,6 +187,8 @@ String get shuffleSeed { ...@@ -187,6 +187,8 @@ String get shuffleSeed {
return _shuffleSeed!; return _shuffleSeed!;
} }
final bool _isRandomizationOff = bool.tryParse(Platform.environment['TEST_RANDOMIZATION_OFF'] ?? '') ?? false;
/// When you call this, you can pass additional arguments to pass custom /// When you call this, you can pass additional arguments to pass custom
/// arguments to flutter test. For example, you might want to call this /// arguments to flutter test. For example, you might want to call this
/// script with the parameter --local-engine=host_debug_unopt to /// script with the parameter --local-engine=host_debug_unopt to
...@@ -2471,7 +2473,7 @@ Future<void> _runFlutterTest(String workingDirectory, { ...@@ -2471,7 +2473,7 @@ Future<void> _runFlutterTest(String workingDirectory, {
final List<String> args = <String>[ final List<String> args = <String>[
'test', 'test',
if (shuffleTests) '--test-randomize-ordering-seed=$shuffleSeed', if (shuffleTests && !_isRandomizationOff) '--test-randomize-ordering-seed=$shuffleSeed',
if (fatalWarnings) '--fatal-warnings', if (fatalWarnings) '--fatal-warnings',
...options, ...options,
...tags, ...tags,
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment