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

Unified Diff: tools/test.dart

Issue 12475010: Revert "Update the test runner to use the new dart:io API" again (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Created 7 years, 9 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « tools/release/version.dart ('k') | tools/test-runtime.dart » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: tools/test.dart
diff --git a/tools/test.dart b/tools/test.dart
index 46c91dfadb8d9c9fba61dac1b814648067a4bc66..dbd5ba87a4d359869b1e07900269ab0798fa45d5 100755
--- a/tools/test.dart
+++ b/tools/test.dart
@@ -1,5 +1,5 @@
#!/usr/bin/env dart
-// Copyright (c) 2013, the Dart project authors. Please see the AUTHORS file
+// Copyright (c) 2012, the Dart project authors. Please see the AUTHORS file
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
@@ -24,7 +24,6 @@
library test;
-import "dart:async";
import "dart:io";
import "testing/dart/test_runner.dart";
import "testing/dart/test_options.dart";
@@ -72,7 +71,7 @@ final TEST_SUITE_DIRECTORIES = [
];
main() {
- var startTime = new DateTime.now();
+ var startTime = new Date.now();
var optionsParser = new TestOptionsParser();
List<Map> configurations = optionsParser.parse(new Options().arguments);
if (configurations == null || configurations.length == 0) return;
@@ -106,7 +105,7 @@ main() {
['Test configurations:'] : ['Test configuration:'];
for (Map conf in configurations) {
List settings = ['compiler', 'runtime', 'mode', 'arch']
- .map((name) => conf[name]).toList();
+ .mappedBy((name) => conf[name]).toList();
if (conf['checked']) settings.add('checked');
output_words.add(settings.join('_'));
}
@@ -117,7 +116,6 @@ main() {
return TestUtils.isBrowserRuntime(config['runtime']);
});
- List<Future> serverFutures = [];
var testSuites = new List<TestSuite>();
var maxBrowserProcesses = maxProcesses;
for (var conf in configurations) {
@@ -128,7 +126,7 @@ main() {
// getCrossOriginPortNumber().
var servers = new TestingServers(new Path(TestUtils.buildDir(conf)),
useContentSecurityPolicy);
- serverFutures.add(servers.startServers('127.0.0.1'));
+ servers.startServers('127.0.0.1');
conf['_servers_'] = servers;
}
@@ -205,22 +203,13 @@ main() {
}
eventListener.add(new ExitCodeSetter());
- void startProcessQueue() {
- // Start process queue.
- new ProcessQueue(maxProcesses,
- maxBrowserProcesses,
- startTime,
- testSuites,
- eventListener,
- allTestsFinished,
- verbose,
- listTests);
- }
-
- // Start all the HTTP servers required before starting the process queue.
- if (serverFutures.isEmpty) {
- startProcessQueue();
- } else {
- Future.wait(serverFutures).then((_) => startProcessQueue());
- }
+ // Start process queue.
+ new ProcessQueue(maxProcesses,
+ maxBrowserProcesses,
+ startTime,
+ testSuites,
+ eventListener,
+ allTestsFinished,
+ verbose,
+ listTests);
}
« no previous file with comments | « tools/release/version.dart ('k') | tools/test-runtime.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698