| Index: tools/testing/dart/test_runner.dart
|
| diff --git a/tools/testing/dart/test_runner.dart b/tools/testing/dart/test_runner.dart
|
| index 9dd56f6e8a9c9759a158cded206be429817ba7d0..c36e80991b2c6e0a9daad41efb4167b46b9ad575 100644
|
| --- a/tools/testing/dart/test_runner.dart
|
| +++ b/tools/testing/dart/test_runner.dart
|
| @@ -4,8 +4,8 @@
|
|
|
| #library("test_runner");
|
|
|
| -
|
| #import("status_file_parser.dart");
|
| +#import("test_progress.dart");
|
|
|
| /**
|
| * Classes and methods for executing tests.
|
| @@ -98,7 +98,6 @@ class RunningProcess {
|
| List<String> stderr;
|
| List<Function> handlers;
|
|
|
| -
|
| RunningProcess(this.testCase, [this.timeout = NO_TIMEOUT]);
|
|
|
| void exitHandler(int exitCode) {
|
| @@ -153,18 +152,20 @@ class ProcessQueue {
|
| int numProcesses = 0;
|
| final int maxProcesses;
|
| Queue<TestCase> tests;
|
| + ProgressIndicator progress;
|
|
|
| - ProcessQueue(this.maxProcesses) : tests = new Queue<TestCase>();
|
| + ProcessQueue(this.maxProcesses, this.progress)
|
| + : tests = new Queue<TestCase>();
|
|
|
| tryRunTest() {
|
| if (numProcesses < maxProcesses && !tests.isEmpty()) {
|
| TestCase test = tests.removeFirst();
|
| - print("running ${test.displayName}");
|
| + progress.start(test);
|
| // TODO(whesse): Refactor into various test output methods.
|
| Function old_callback = test.completedHandler;
|
| Function wrapper = (TestCase test_arg) {
|
| numProcesses--;
|
| - print("finished ${test_arg.displayName}");
|
| + progress.done(test_arg);
|
| tryRunTest();
|
| old_callback(test_arg);
|
| };
|
| @@ -177,6 +178,7 @@ class ProcessQueue {
|
| }
|
|
|
| runTest(TestCase test) {
|
| + progress.testAdded();
|
| tests.add(test);
|
| tryRunTest();
|
| }
|
|
|