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

Unified Diff: tools/testing/dart/test_options.dart

Issue 9110031: Enable webdriver component in test.dart (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Created 8 years, 11 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 | « no previous file | tools/testing/dart/test_runner.dart » ('j') | tools/testing/dart/test_suite.dart » ('J')
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: tools/testing/dart/test_options.dart
diff --git a/tools/testing/dart/test_options.dart b/tools/testing/dart/test_options.dart
index 00ff805bc62ce0f46a94a4751ebfa61206c0dc8a..163dda5477f6bb18a6effc9c565ad722b474ac85 100644
--- a/tools/testing/dart/test_options.dart
+++ b/tools/testing/dart/test_options.dart
@@ -62,7 +62,7 @@ is 'dart file.dart' and you specify special command
'The component to test against',
['-c', '--component'],
['most', 'vm', 'dartc', 'frog', 'frogsh', 'leg',
- 'dartium', 'chromium', 'frogium'],
+ 'dartium', 'chromium', 'frogium', 'webdriver'],
'vm'),
new _TestOptionSpecification(
'arch',
@@ -150,7 +150,13 @@ is 'dart file.dart' and you specify special command
['--time'],
[],
false,
- 'bool')];
+ 'bool'),
+ new _TestOptionSpecification(
+ 'flag',
+ 'Component-specific extra flags, comma separated',
+ ['--flag'],
+ [],
+ '')];
}
@@ -181,7 +187,7 @@ is 'dart file.dart' and you specify special command
_printHelp();
return null;
}
- var split = arg.lastIndexOf('=');
+ var split = arg.indexOf('=');
if (split == -1) {
name = arg;
// Boolean options do not have a value.
@@ -246,10 +252,12 @@ is 'dart file.dart' and you specify special command
}
} else {
assert(spec.type == 'string');
- for (var v in value.split(',')) {
- if (spec.values.lastIndexOf(v) == -1) {
- print('Unknown value ($v) for option $name');
- exit(1);
+ if (!spec.values.isEmpty()) {
+ for (var v in value.split(',')) {
+ if (spec.values.lastIndexOf(v) == -1) {
+ print('Unknown value ($v) for option $name');
+ exit(1);
+ }
}
}
configuration[spec.name] = value;
« no previous file with comments | « no previous file | tools/testing/dart/test_runner.dart » ('j') | tools/testing/dart/test_suite.dart » ('J')

Powered by Google App Engine
This is Rietveld 408576698