| OLD | NEW |
| 1 // Copyright (c) 2017, the Dart project authors. Please see the AUTHORS file | 1 // Copyright (c) 2017, the Dart project authors. Please see the AUTHORS file |
| 2 // for details. All rights reserved. Use of this source code is governed by a | 2 // for details. All rights reserved. Use of this source code is governed by a |
| 3 // BSD-style license that can be found in the LICENSE file. | 3 // BSD-style license that can be found in the LICENSE file. |
| 4 | 4 |
| 5 /// Compares the test log of a build step with previous builds. | 5 /// Compares the test log of a build step with previous builds. |
| 6 /// | 6 /// |
| 7 /// Use this to detect flakiness of failures, especially timeouts. | 7 /// Use this to detect flakiness of failures, especially timeouts. |
| 8 | 8 |
| 9 import 'dart:async'; | 9 import 'dart:async'; |
| 10 | 10 |
| (...skipping 95 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 106 }); | 106 }); |
| 107 } | 107 } |
| 108 | 108 |
| 109 Future runSingleTest(BuildbotClient client, String testUri, int runCount, | 109 Future runSingleTest(BuildbotClient client, String testUri, int runCount, |
| 110 Map<int, Map<String, String>> expectedResult) async { | 110 Map<int, Map<String, String>> expectedResult) async { |
| 111 print('Testing single compare-failures: $testUri runCount=$runCount'); | 111 print('Testing single compare-failures: $testUri runCount=$runCount'); |
| 112 Map<BuildUri, List<BuildResult>> buildResults = | 112 Map<BuildUri, List<BuildResult>> buildResults = |
| 113 await loadBuildResults(client, [testUri], runCount: runCount); | 113 await loadBuildResults(client, [testUri], runCount: runCount); |
| 114 print('- checking results for ${buildResults.keys}'); | 114 print('- checking results for ${buildResults.keys}'); |
| 115 if (LOG) { | 115 if (LOG) { |
| 116 printBuildResultsSummary(buildResults); | 116 printBuildResultsSummary(buildResults, [testUri]); |
| 117 } | 117 } |
| 118 Expect.equals(1, buildResults.length); | 118 Expect.equals(1, buildResults.length); |
| 119 testSingleResults(expectedResult, buildResults.values.first); | 119 testSingleResults(expectedResult, buildResults.values.first); |
| 120 } | 120 } |
| OLD | NEW |