| OLD | NEW |
| 1 // Copyright (c) 2012, the Dart project authors. Please see the AUTHORS file | 1 // Copyright (c) 2012, 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 part of testrunner; | 5 part of testrunner; |
| 6 | 6 |
| 7 /** Create and return an options parser for the test runner. */ | 7 /** Create and return an options parser for the test runner. */ |
| 8 ArgParser getOptionParser() { | 8 ArgParser getOptionParser() { |
| 9 var parser = new ArgParser(); | 9 var parser = new ArgParser(); |
| 10 | 10 |
| (...skipping 124 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 135 'file. Note that in some async cases this may result in multiple ' | 135 'file. Note that in some async cases this may result in multiple ' |
| 136 'messages for a single test.', | 136 'messages for a single test.', |
| 137 defaultsTo: false); | 137 defaultsTo: false); |
| 138 | 138 |
| 139 parser.addFlag('regenerate', | 139 parser.addFlag('regenerate', |
| 140 help: 'Regenerate layout test expectation files.', | 140 help: 'Regenerate layout test expectation files.', |
| 141 defaultsTo: false); | 141 defaultsTo: false); |
| 142 | 142 |
| 143 parser.addFlag('server', help: 'Run an HTTP server.', defaultsTo: false); | 143 parser.addFlag('server', help: 'Run an HTTP server.', defaultsTo: false); |
| 144 | 144 |
| 145 parser.addOption('port', help: 'Port to use for HTTP server', | 145 parser.addOption('port', help: 'Port to use for HTTP server'); |
| 146 defaultsTo: '8080'); | |
| 147 | 146 |
| 148 parser.addOption('root', | 147 parser.addOption('root', |
| 149 help: 'Root directory for HTTP server for static files'); | 148 help: 'Root directory for HTTP server for static files'); |
| 150 | 149 |
| 151 parser.addOption('unittest', help: '#import path for unit test library.'); | 150 parser.addOption('unittest', help: '#import path for unit test library.'); |
| 152 | 151 |
| 153 parser.addOption('pipeline', | 152 parser.addOption('pipeline', |
| 154 help: 'Pipeline script to use to run each test file.', | 153 help: 'Pipeline script to use to run each test file.', |
| 155 defaultsTo: 'run_pipeline.dart'); | 154 defaultsTo: 'run_pipeline.dart'); |
| 156 | 155 |
| (...skipping 100 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 257 print('--include and --exclude are mutually exclusive.'); | 256 print('--include and --exclude are mutually exclusive.'); |
| 258 return false; | 257 return false; |
| 259 } | 258 } |
| 260 if ((config['layout-text'] || config['layout-pixel']) && | 259 if ((config['layout-text'] || config['layout-pixel']) && |
| 261 config['runtime'] == 'vm') { | 260 config['runtime'] == 'vm') { |
| 262 print('Layout tests must use --runtime values of "drt-dart" or "drt-js"'); | 261 print('Layout tests must use --runtime values of "drt-dart" or "drt-js"'); |
| 263 return false; | 262 return false; |
| 264 } | 263 } |
| 265 return true; | 264 return true; |
| 266 } | 265 } |
| OLD | NEW |