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

Side by Side Diff: dart/tests/standalone/io/test_runner_test.dart

Issue 28613003: Fixed test_runner_test.dart: Use normal TestOptionsParser to get default options (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge
Patch Set: Created 7 years, 2 months 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
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
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 import "dart:io"; 5 import "dart:io";
6 import "dart:isolate"; 6 import "dart:isolate";
7 import "dart:async"; 7 import "dart:async";
8 import "../../../tools/testing/dart/test_runner.dart"; 8 import "../../../tools/testing/dart/test_runner.dart";
9 import "../../../tools/testing/dart/test_suite.dart"; 9 import "../../../tools/testing/dart/test_suite.dart";
10 import "../../../tools/testing/dart/test_progress.dart" as progress; 10 import "../../../tools/testing/dart/test_progress.dart" as progress;
(...skipping 95 matching lines...) Expand 10 before | Expand all | Expand 10 after
106 return new TestCase(name, 106 return new TestCase(name,
107 [command], 107 [command],
108 configuration, 108 configuration,
109 new Set<Expectation>.from(expectations)); 109 new Set<Expectation>.from(expectations));
110 } 110 }
111 } 111 }
112 112
113 void testProcessQueue() { 113 void testProcessQueue() {
114 var maxProcesses = 2; 114 var maxProcesses = 2;
115 var maxBrowserProcesses = maxProcesses; 115 var maxBrowserProcesses = maxProcesses;
116 new ProcessQueue({'noBatch' : true}, maxProcesses, maxBrowserProcesses, 116 var config = new TestOptionsParser().parse(['--nobatch'])[0];
117 new ProcessQueue(config, maxProcesses, maxBrowserProcesses,
117 new DateTime.now(), [new CustomTestSuite()], 118 new DateTime.now(), [new CustomTestSuite()],
118 [new EventListener()], TestController.finished); 119 [new EventListener()], TestController.finished);
119 } 120 }
120 121
121 class EventListener extends progress.EventListener{ 122 class EventListener extends progress.EventListener{
122 void done(TestCase test) { 123 void done(TestCase test) {
123 TestController.processCompletedTest(test); 124 TestController.processCompletedTest(test);
124 } 125 }
125 } 126 }
126 127
(...skipping 14 matching lines...) Expand all
141 break; 142 break;
142 case 'timeout': 143 case 'timeout':
143 // Run for 10 seconds, then exit. This tests a 2 second timeout. 144 // Run for 10 seconds, then exit. This tests a 2 second timeout.
144 new Timer(new Duration(seconds: 10), (){ }); 145 new Timer(new Duration(seconds: 10), (){ });
145 break; 146 break;
146 default: 147 default:
147 throw "Unknown option ${arguments[0]} passed to test_runner_test"; 148 throw "Unknown option ${arguments[0]} passed to test_runner_test";
148 } 149 }
149 } 150 }
150 } 151 }
OLDNEW
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698