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

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

Issue 8539044: Enable co19 test suite on dart test scripts. (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Address review comments. Created 9 years, 1 month 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 | « tools/testing/dart/status_file_parser.dart ('k') | tools/testing/dart/test_runner.dart » ('j') | 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) 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_options_parser"); 5 #library("test_options_parser");
6 6
7 List<String> defaultTestSelectors = const ['standalone', 'corelib']; 7 List<String> defaultTestSelectors = const ['standalone', 'corelib', 'co19'];
8 8
9 /** 9 /**
10 * Specification of a single test option. 10 * Specification of a single test option.
11 * 11 *
12 * The name of the specification is used as the key for the option in 12 * The name of the specification is used as the key for the option in
13 * the Map returned from the [TestOptionParser] parse method. 13 * the Map returned from the [TestOptionParser] parse method.
14 */ 14 */
15 class _TestOptionSpecification { 15 class _TestOptionSpecification {
16 _TestOptionSpecification(this.name, 16 _TestOptionSpecification(this.name,
17 this.description, 17 this.description,
(...skipping 32 matching lines...) Expand 10 before | Expand all | Expand 10 after
50 ['most', 'vm', 'dartc', 'frog', 'frogsh', 'leg', 50 ['most', 'vm', 'dartc', 'frog', 'frogsh', 'leg',
51 'chromium', 'dartium', 'frogium', 'webdriver'], 51 'chromium', 'dartium', 'frogium', 'webdriver'],
52 'vm'), 52 'vm'),
53 new _TestOptionSpecification( 53 new _TestOptionSpecification(
54 'architecture', 54 'architecture',
55 'The architecture to run tests for', 55 'The architecture to run tests for',
56 ['-a', '--arch'], 56 ['-a', '--arch'],
57 ['all', 'ia32', 'x64', 'simarm'], 57 ['all', 'ia32', 'x64', 'simarm'],
58 'ia32'), 58 'ia32'),
59 new _TestOptionSpecification( 59 new _TestOptionSpecification(
60 'os', 60 'system',
61 'The operating system to run tests on', 61 'The operating system to run tests on',
62 ['-o', '--os'], 62 ['-s', '--system'],
63 ['linux', 'macos', 'windows'], 63 ['linux', 'macos', 'windows'],
64 new Platform().operatingSystem()), 64 new Platform().operatingSystem()),
65 new _TestOptionSpecification( 65 new _TestOptionSpecification(
66 'checked', 66 'checked',
67 'Run tests in checked mode', 67 'Run tests in checked mode',
68 ['--checked'], 68 ['--checked'],
69 [], 69 [],
70 false, 70 false,
71 'bool'), 71 'bool'),
72 new _TestOptionSpecification( 72 new _TestOptionSpecification(
(...skipping 123 matching lines...) Expand 10 before | Expand all | Expand 10 after
196 if (configuration['architecture'] == 'all') { 196 if (configuration['architecture'] == 'all') {
197 configuration['architecture'] = 'ia32,x64,simarm'; 197 configuration['architecture'] = 'ia32,x64,simarm';
198 } 198 }
199 if (configuration['mode'] == 'all') { 199 if (configuration['mode'] == 'all') {
200 configuration['mode'] = 'debug,release'; 200 configuration['mode'] = 'debug,release';
201 } 201 }
202 if (configuration['component'] == 'most') { 202 if (configuration['component'] == 'most') {
203 configuration['component'] = 'vm,dartc'; 203 configuration['component'] = 'vm,dartc';
204 } 204 }
205 205
206 // Create the artificial 'unchecked' option that test status files
207 // expect.
208 configuration['unchecked'] = !configuration['checked'];
209
206 // Expand the test selectors into simple regular expressions to be 210 // Expand the test selectors into simple regular expressions to be
207 // used on the full path of a test file. If no selectors are 211 // used on the full path of a test file. If no selectors are
208 // explicitly given use the default suite patterns. 212 // explicitly given use the default suite patterns.
209 List patterns = configuration['patterns']; 213 List patterns = configuration['patterns'];
210 if (patterns == null) { 214 if (patterns == null) {
211 patterns = new List.from(defaultTestSelectors); 215 patterns = new List.from(defaultTestSelectors);
212 } 216 }
213 for (var i = 0; i < patterns.length; i++) { 217 for (var i = 0; i < patterns.length; i++) {
214 patterns[i] = patterns[i].replaceAll('*', '.*'); 218 patterns[i] = patterns[i].replaceAll('*', '.*');
215 patterns[i] = patterns[i].replaceAll('/', '.*'); 219 patterns[i] = patterns[i].replaceAll('/', '.*');
(...skipping 106 matching lines...) Expand 10 before | Expand all | Expand 10 after
322 if (option.keys.some((key) => key == name)) { 326 if (option.keys.some((key) => key == name)) {
323 return option; 327 return option;
324 } 328 }
325 } 329 }
326 return null; 330 return null;
327 } 331 }
328 332
329 333
330 List<_TestOptionSpecification> _options; 334 List<_TestOptionSpecification> _options;
331 } 335 }
OLDNEW
« no previous file with comments | « tools/testing/dart/status_file_parser.dart ('k') | tools/testing/dart/test_runner.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698