| OLD | NEW |
| 1 #!/usr/bin/env dart | 1 #!/usr/bin/env dart |
| 2 // Copyright (c) 2012, the Dart project authors. Please see the AUTHORS file | 2 // Copyright (c) 2012, the Dart project authors. Please see the AUTHORS file |
| 3 // for details. All rights reserved. Use of this source code is governed by a | 3 // for details. All rights reserved. Use of this source code is governed by a |
| 4 // BSD-style license that can be found in the LICENSE file. | 4 // BSD-style license that can be found in the LICENSE file. |
| 5 | 5 |
| 6 /** | 6 /** |
| 7 * This file is the entrypoint of the dart test suite. This suite is used | 7 * This file is the entrypoint of the dart test suite. This suite is used |
| 8 * to test: | 8 * to test: |
| 9 * | 9 * |
| 10 * 1. the dart vm | 10 * 1. the dart vm |
| (...skipping 17 matching lines...) Expand all Loading... |
| 28 #import("testing/dart/test_runner.dart"); | 28 #import("testing/dart/test_runner.dart"); |
| 29 #import("testing/dart/test_options.dart"); | 29 #import("testing/dart/test_options.dart"); |
| 30 #import("testing/dart/test_suite.dart"); | 30 #import("testing/dart/test_suite.dart"); |
| 31 | 31 |
| 32 #import("../client/tests/dartc/test_config.dart"); | 32 #import("../client/tests/dartc/test_config.dart"); |
| 33 #import("../compiler/tests/dartc/test_config.dart"); | 33 #import("../compiler/tests/dartc/test_config.dart"); |
| 34 #import("../frog/tests/await/test_config.dart"); | 34 #import("../frog/tests/await/test_config.dart"); |
| 35 #import("../runtime/tests/vm/test_config.dart"); | 35 #import("../runtime/tests/vm/test_config.dart"); |
| 36 #import("../samples/tests/samples/test_config.dart"); | 36 #import("../samples/tests/samples/test_config.dart"); |
| 37 #import("../tests/co19/test_config.dart"); | 37 #import("../tests/co19/test_config.dart"); |
| 38 #import("../tests/language/test_config.dart"); | |
| 39 #import("../tests/lib/test_config.dart"); | 38 #import("../tests/lib/test_config.dart"); |
| 40 #import("../tests/standalone/test_config.dart"); | 39 #import("../tests/standalone/test_config.dart"); |
| 41 #import("../tests/utils/test_config.dart"); | 40 #import("../tests/utils/test_config.dart"); |
| 42 | 41 |
| 43 /** | 42 /** |
| 44 * The directories that contain test suites which follow the conventions | 43 * The directories that contain test suites which follow the conventions |
| 45 * required by [StandardTestSuite]'s forDirectory constructor. | 44 * required by [StandardTestSuite]'s forDirectory constructor. |
| 46 * New test suites should follow this convention because it makes it much | 45 * New test suites should follow this convention because it makes it much |
| 47 * simpler to add them to test.dart. Existing test suites should be | 46 * simpler to add them to test.dart. Existing test suites should be |
| 48 * moved to here, if possible. | 47 * moved to here, if possible. |
| 49 */ | 48 */ |
| 50 final TEST_SUITE_DIRECTORIES = const [ | 49 final TEST_SUITE_DIRECTORIES = const [ |
| 51 'frog/tests/frog', | 50 'frog/tests/frog', |
| 52 'frog/tests/frog_native', | 51 'frog/tests/frog_native', |
| 53 'frog/tests/leg', | 52 'frog/tests/leg', |
| 54 'frog/tests/leg_only', | 53 'frog/tests/leg_only', |
| 55 'tests/benchmark_smoke', | 54 'tests/benchmark_smoke', |
| 56 'tests/corelib', | 55 'tests/corelib', |
| 57 'tests/dom', | 56 'tests/dom', |
| 58 'tests/html', | 57 'tests/html', |
| 59 'tests/isolate', | 58 'tests/isolate', |
| 60 'tests/json', | 59 'tests/json', |
| 60 'tests/language', |
| 61 'utils/tests/css', | 61 'utils/tests/css', |
| 62 'utils/tests/peg', | 62 'utils/tests/peg', |
| 63 'utils/tests/pub', | 63 'utils/tests/pub', |
| 64 ]; | 64 ]; |
| 65 | 65 |
| 66 main() { | 66 main() { |
| 67 var startTime = new Date.now(); | 67 var startTime = new Date.now(); |
| 68 var optionsParser = new TestOptionsParser(); | 68 var optionsParser = new TestOptionsParser(); |
| 69 List<Map> configurations = optionsParser.parse(new Options().arguments); | 69 List<Map> configurations = optionsParser.parse(new Options().arguments); |
| 70 if (configurations == null || configurations.length == 0) return; | 70 if (configurations == null || configurations.length == 0) return; |
| (...skipping 29 matching lines...) Expand all Loading... |
| 100 } | 100 } |
| 101 | 101 |
| 102 var conf = configurationIterator.next(); | 102 var conf = configurationIterator.next(); |
| 103 for (String key in selectors.getKeys()) { | 103 for (String key in selectors.getKeys()) { |
| 104 if (key == 'samples') { | 104 if (key == 'samples') { |
| 105 queue.addTestSuite(new SamplesTestSuite(conf)); | 105 queue.addTestSuite(new SamplesTestSuite(conf)); |
| 106 } else if (key == 'standalone') { | 106 } else if (key == 'standalone') { |
| 107 queue.addTestSuite(new StandaloneTestSuite(conf)); | 107 queue.addTestSuite(new StandaloneTestSuite(conf)); |
| 108 } else if (key == 'co19') { | 108 } else if (key == 'co19') { |
| 109 queue.addTestSuite(new Co19TestSuite(conf)); | 109 queue.addTestSuite(new Co19TestSuite(conf)); |
| 110 } else if (key == 'language') { | |
| 111 queue.addTestSuite(new LanguageTestSuite(conf)); | |
| 112 } else if (key == 'lib') { | 110 } else if (key == 'lib') { |
| 113 queue.addTestSuite(new LibTestSuite(conf)); | 111 queue.addTestSuite(new LibTestSuite(conf)); |
| 114 } else if (key == 'utils') { | 112 } else if (key == 'utils') { |
| 115 queue.addTestSuite(new UtilsTestSuite(conf)); | 113 queue.addTestSuite(new UtilsTestSuite(conf)); |
| 116 } else if (conf['runtime'] == 'vm' && key == 'vm') { | 114 } else if (conf['runtime'] == 'vm' && key == 'vm') { |
| 117 queue.addTestSuite(new VMTestSuite(conf)); | 115 queue.addTestSuite(new VMTestSuite(conf)); |
| 118 queue.addTestSuite(new VMDartTestSuite(conf)); | 116 queue.addTestSuite(new VMDartTestSuite(conf)); |
| 119 } else if (conf['compiler'] == 'dartc' && key == 'dartc') { | 117 } else if (conf['compiler'] == 'dartc' && key == 'dartc') { |
| 120 queue.addTestSuite(new ClientDartcTestSuite(conf)); | 118 queue.addTestSuite(new ClientDartcTestSuite(conf)); |
| 121 } else if (conf['compiler'] == 'dartc' && key == 'dartc') { | 119 } else if (conf['compiler'] == 'dartc' && key == 'dartc') { |
| (...skipping 17 matching lines...) Expand all Loading... |
| 139 // Start process queue. | 137 // Start process queue. |
| 140 var queue = new ProcessQueue(maxProcesses, | 138 var queue = new ProcessQueue(maxProcesses, |
| 141 progressIndicator, | 139 progressIndicator, |
| 142 startTime, | 140 startTime, |
| 143 printTiming, | 141 printTiming, |
| 144 enqueueConfiguration, | 142 enqueueConfiguration, |
| 145 verbose, | 143 verbose, |
| 146 listTests, | 144 listTests, |
| 147 keepGeneratedTests); | 145 keepGeneratedTests); |
| 148 } | 146 } |
| OLD | NEW |