OLD | NEW |
1 // Copyright (c) 2013, the Dart project authors. Please see the AUTHORS file | 1 // Copyright (c) 2013, 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 runtime.coverage; | 5 library runtime.coverage; |
6 | 6 |
7 import 'dart:io'; | 7 import 'dart:io'; |
8 | 8 |
9 import 'package:args/args.dart'; | 9 import 'package:args/args.dart'; |
10 | 10 |
11 import 'package:analyzer_experimental/src/services/runtime/log.dart' as log; | 11 import 'package:analyzer/src/services/runtime/log.dart' as log; |
12 import 'package:analyzer_experimental/src/services/runtime/coverage/coverage_imp
l.dart'; | 12 import 'package:analyzer/src/services/runtime/coverage/coverage_impl.dart'; |
13 | 13 |
14 | 14 |
15 main(args) { | 15 main(args) { |
16 ArgResults options; | 16 ArgResults options; |
17 try { | 17 try { |
18 options = _argParser.parse(args); | 18 options = _argParser.parse(args); |
19 } on FormatException catch (e) { | 19 } on FormatException catch (e) { |
20 print(e.message); | 20 print(e.message); |
21 print('Run "coverage --help" to see available options.'); | 21 print('Run "coverage --help" to see available options.'); |
22 exit(ERROR); | 22 exit(ERROR); |
(...skipping 57 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
80 printUsage([var description = 'Code coverage tool for Dart.']) { | 80 printUsage([var description = 'Code coverage tool for Dart.']) { |
81 var usage = _argParser.getUsage(); | 81 var usage = _argParser.getUsage(); |
82 print('$description\n'); | 82 print('$description\n'); |
83 print('Usage: coverage [options] <script>\n'); | 83 print('Usage: coverage [options] <script>\n'); |
84 print('$usage\n'); | 84 print('$usage\n'); |
85 } | 85 } |
86 | 86 |
87 | 87 |
88 /// General error code. | 88 /// General error code. |
89 const ERROR = 1; | 89 const ERROR = 1; |
OLD | NEW |