| OLD | NEW |
| 1 // Copyright (c) 2012, the Dart project authors. Please see the AUTHORS file | 1 // Copyright (c) 2012, 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("test_runner.dart"); | 8 #import("test_runner.dart"); |
| 9 #import("test_suite.dart"); | 9 #import("test_suite.dart"); |
| 10 | 10 |
| (...skipping 391 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 402 void _printFailureOutput(TestCase test) { | 402 void _printFailureOutput(TestCase test) { |
| 403 String status = '${test.displayName}: ${test.output.result}'; | 403 String status = '${test.displayName}: ${test.output.result}'; |
| 404 List<String> configs = | 404 List<String> configs = |
| 405 statusToConfigs.putIfAbsent(status, () => <String>[]); | 405 statusToConfigs.putIfAbsent(status, () => <String>[]); |
| 406 configs.add(test.configurationString); | 406 configs.add(test.configurationString); |
| 407 } | 407 } |
| 408 | 408 |
| 409 String _extractRuntime(String configuration) { | 409 String _extractRuntime(String configuration) { |
| 410 // Extract runtime from a configuration, for example, | 410 // Extract runtime from a configuration, for example, |
| 411 // 'none-vm-checked release_ia32'. | 411 // 'none-vm-checked release_ia32'. |
| 412 List<String> runtime = config.split(' ')[0].split('-'); | 412 List<String> runtime = configuration.split(' ')[0].split('-'); |
| 413 return '${runtime[0]}-${runtime[1]}'; | 413 return '${runtime[0]}-${runtime[1]}'; |
| 414 } | 414 } |
| 415 | 415 |
| 416 void _printFailureSummary() { | 416 void _printFailureSummary() { |
| 417 Map<String, List<String>> groupedStatuses = new Map<String, List<String>>(); | 417 Map<String, List<String>> groupedStatuses = new Map<String, List<String>>(); |
| 418 statusToConfigs.forEach((String status, List<String> configs) { | 418 statusToConfigs.forEach((String status, List<String> configs) { |
| 419 Map<String, List<String>> runtimeToConfiguration = | 419 Map<String, List<String>> runtimeToConfiguration = |
| 420 new Map<String, List<String>>(); | 420 new Map<String, List<String>>(); |
| 421 for (String config in configs) { | 421 for (String config in configs) { |
| 422 String runtime = _extractRuntime(config); | 422 String runtime = _extractRuntime(config); |
| (...skipping 15 matching lines...) Expand all Loading... |
| 438 print(''); | 438 print(''); |
| 439 print('$config:'); | 439 print('$config:'); |
| 440 statuses.sort((a, b) => a.compareTo(b)); | 440 statuses.sort((a, b) => a.compareTo(b)); |
| 441 for (String status in statuses) { | 441 for (String status in statuses) { |
| 442 print(' $status'); | 442 print(' $status'); |
| 443 } | 443 } |
| 444 }); | 444 }); |
| 445 _printStatus(); | 445 _printStatus(); |
| 446 } | 446 } |
| 447 } | 447 } |
| OLD | NEW |