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

Unified Diff: tools/test-runtime.dart

Issue 8773036: Make multi tests work with DartC. (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Address comments 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « tools/test.dart ('k') | tools/testing/dart/multitest.dart » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: tools/test-runtime.dart
diff --git a/tools/test-runtime.dart b/tools/test-runtime.dart
index 7f376088a47e123cc3f22e59ff13185e014ec426..47b9f59dd8bf901db445d6b19b4de7519b3f858c 100644
--- a/tools/test-runtime.dart
+++ b/tools/test-runtime.dart
@@ -22,15 +22,22 @@
main() {
var startTime = new Date.now();
var optionsParser = new TestOptionsParser();
- var configurations = optionsParser.parse(new Options().arguments);
+ List<Map> configurations = optionsParser.parse(new Options().arguments);
if (configurations == null) return;
+
// Extract global options from first configuration.
var firstConf = configurations[0];
- var queue = new ProcessQueue(firstConf['tasks'],
- firstConf['progress'],
- startTime);
Map<String, RegExp> selectors = firstConf['selectors'];
- for (var conf in configurations) {
+ var maxProcesses = firstConf['tasks'];
+ var progressIndicator = firstConf['progress'];
+
+ var configurationIterator = configurations.iterator();
+ bool enqueueConfiguration(ProcessQueue queue) {
+ if (!configurationIterator.hasNext()) {
+ return false;
+ }
+
+ var conf = configurationIterator.next();
if (selectors.containsKey('standalone')) {
queue.addTestSuite(new StandaloneTestSuite(conf));
}
@@ -52,5 +59,13 @@ main() {
if (conf['component'] == 'vm' && selectors.containsKey('vm')) {
queue.addTestSuite(new VMTestSuite(conf));
}
+
+ return true;
}
+
+ // Start process queue.
+ var queue = new ProcessQueue(firstConf['tasks'],
+ firstConf['progress'],
+ startTime,
+ enqueueConfiguration);
}
« no previous file with comments | « tools/test.dart ('k') | tools/testing/dart/multitest.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698