| OLD | NEW |
| 1 // Copyright (c) 2013, the Dart project authors. Please see the AUTHORS file | 1 // Copyright (c) 2013, 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 library test_progress; | 5 library test_progress; |
| 6 | 6 |
| 7 import "dart:io"; | 7 import "dart:io"; |
| 8 import "dart:io" as io; | 8 import "dart:io" as io; |
| 9 import "http_server.dart" as http_server; | 9 import "http_server.dart" as http_server; |
| 10 import "status_file_parser.dart"; | 10 import "status_file_parser.dart"; |
| (...skipping 155 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 166 var buf = new StringBuffer(); | 166 var buf = new StringBuffer(); |
| 167 for (var l in _buildFailureOutput(test)) { | 167 for (var l in _buildFailureOutput(test)) { |
| 168 buf.write("$l\n"); | 168 buf.write("$l\n"); |
| 169 } | 169 } |
| 170 _appendToFlakyFile(buf.toString()); | 170 _appendToFlakyFile(buf.toString()); |
| 171 } | 171 } |
| 172 } | 172 } |
| 173 | 173 |
| 174 void _appendToFlakyFile(String msg) { | 174 void _appendToFlakyFile(String msg) { |
| 175 var file = new File(TestUtils.flakyFileName()); | 175 var file = new File(TestUtils.flakyFileName()); |
| 176 var fd = file.openSync(mode: FileMode.APPEND); | 176 var fd = file.openSync(FileMode.APPEND); |
| 177 fd.writeStringSync(msg); | 177 fd.writeStringSync(msg); |
| 178 fd.closeSync(); | 178 fd.closeSync(); |
| 179 } | 179 } |
| 180 } | 180 } |
| 181 | 181 |
| 182 class SummaryPrinter extends EventListener { | 182 class SummaryPrinter extends EventListener { |
| 183 void allTestsKnown() { | 183 void allTestsKnown() { |
| 184 if (SummaryReport.total > 0) { | 184 if (SummaryReport.total > 0) { |
| 185 SummaryReport.printReport(); | 185 SummaryReport.printReport(); |
| 186 } | 186 } |
| (...skipping 333 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 520 print('@@@BUILD_STEP $stepName failures@@@'); | 520 print('@@@BUILD_STEP $stepName failures@@@'); |
| 521 } | 521 } |
| 522 for (String line in _failureSummary) { | 522 for (String line in _failureSummary) { |
| 523 print(line); | 523 print(line); |
| 524 } | 524 } |
| 525 print(''); | 525 print(''); |
| 526 } | 526 } |
| 527 print(_buildSummaryEnd(_failedTests)); | 527 print(_buildSummaryEnd(_failedTests)); |
| 528 } | 528 } |
| 529 } | 529 } |
| OLD | NEW |