Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(644)

Side by Side Diff: tools/testing/dart/test_runner.dart

Issue 8845001: Add --time option to dart test scripts. (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Runtime test script Created 9 years ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
OLDNEW
1 // Copyright (c) 2011, the Dart project authors. Please see the AUTHORS file 1 // Copyright (c) 2011, 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_runner"); 5 #library("test_runner");
6 6
7 #import("status_file_parser.dart"); 7 #import("status_file_parser.dart");
8 #import("test_progress.dart"); 8 #import("test_progress.dart");
9 #import("test_suite.dart"); 9 #import("test_suite.dart");
10 10
(...skipping 313 matching lines...) Expand 10 before | Expand all | Expand 10 after
324 bool _verbose; 324 bool _verbose;
325 Function _enqueueMoreWork; 325 Function _enqueueMoreWork;
326 Queue<TestCase> _tests; 326 Queue<TestCase> _tests;
327 ProgressIndicator _progress; 327 ProgressIndicator _progress;
328 // For dartc batch processing we keep a list of batch processes. 328 // For dartc batch processing we keep a list of batch processes.
329 List<DartcBatchRunnerProcess> _batchProcesses; 329 List<DartcBatchRunnerProcess> _batchProcesses;
330 330
331 ProcessQueue(int this._maxProcesses, 331 ProcessQueue(int this._maxProcesses,
332 String progress, 332 String progress,
333 bool this._verbose, 333 bool this._verbose,
334 Date start_time, 334 Date startTime,
335 bool printTiming,
335 Function this._enqueueMoreWork) 336 Function this._enqueueMoreWork)
336 : _tests = new Queue<TestCase>(), 337 : _tests = new Queue<TestCase>(),
337 _progress = new ProgressIndicator.fromName(progress, start_time), 338 _progress = new ProgressIndicator.fromName(progress,
339 startTime,
340 printTiming),
338 _batchProcesses = new List<DartcBatchRunnerProcess>() { 341 _batchProcesses = new List<DartcBatchRunnerProcess>() {
339 if (!_enqueueMoreWork(this)) _progress.allDone(); 342 if (!_enqueueMoreWork(this)) _progress.allDone();
340 } 343 }
341 344
342 void addTestSuite(TestSuite testSuite) { 345 void addTestSuite(TestSuite testSuite) {
343 _activeTestListers++; 346 _activeTestListers++;
344 testSuite.forEachTest(_runTest, _testListerDone); 347 testSuite.forEachTest(_runTest, _testListerDone);
345 } 348 }
346 349
347 void _testListerDone() { 350 void _testListerDone() {
(...skipping 56 matching lines...) Expand 10 before | Expand all | Expand 10 after
404 if (test.executablePath.contains('compiler')) { 407 if (test.executablePath.contains('compiler')) {
405 _ensureDartcBatchRunnersStarted(test.executablePath); 408 _ensureDartcBatchRunnersStarted(test.executablePath);
406 _getDartcBatchRunnerProcess().startTest(test); 409 _getDartcBatchRunnerProcess().startTest(test);
407 } else { 410 } else {
408 new RunningProcess(test).start(); 411 new RunningProcess(test).start();
409 } 412 }
410 _numProcesses++; 413 _numProcesses++;
411 } 414 }
412 } 415 }
413 } 416 }
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698