Chromium Code Reviews| OLD | NEW |
|---|---|
| 1 // Copyright (c) 2016, the Dart project authors. Please see the AUTHORS file | 1 // Copyright (c) 2016, 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 dart2js.analyze_test.test; | 5 library dart2js.analyze_test.test; |
| 6 | 6 |
| 7 import 'dart:io'; | 7 import 'dart:io'; |
| 8 | 8 |
| 9 import 'package:async_helper/async_helper.dart'; | 9 import 'package:async_helper/async_helper.dart'; |
| 10 import 'package:compiler/src/apiimpl.dart' show | 10 import 'package:compiler/src/apiimpl.dart' show |
| (...skipping 39 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 50 // Broken tests: | 50 // Broken tests: |
| 51 "http_test.dart", | 51 "http_test.dart", |
| 52 ]; | 52 ]; |
| 53 | 53 |
| 54 const List<MessageKind> MESSAGE_SKIP_LIST = const <MessageKind>[ | 54 const List<MessageKind> MESSAGE_SKIP_LIST = const <MessageKind>[ |
| 55 // TODO(johnniwinther): Support checking of this warning. (Issue 26132) | 55 // TODO(johnniwinther): Support checking of this warning. (Issue 26132) |
| 56 MessageKind.IMPORT_EXPERIMENTAL_MIRRORS, | 56 MessageKind.IMPORT_EXPERIMENTAL_MIRRORS, |
| 57 ]; | 57 ]; |
| 58 | 58 |
| 59 main(List<String> arguments) { | 59 main(List<String> arguments) { |
| 60 List<String> options = <String>[]; | 60 List<String> options = <String>[]..addAll(arguments); |
|
eernst
2016/04/12 12:10:47
On line 66 it looks like some elements in `argumen
Johnni Winther
2016/04/12 12:38:36
Done.
| |
| 61 if (arguments.contains('-v') || arguments.contains(Flags.verbose)) { | 61 if (arguments.contains(Flags.verbose)) { |
|
eernst
2016/04/12 12:10:47
I assume the intention is to disable the '-v' form
Johnni Winther
2016/04/12 12:38:36
Dooh. Removed the wrong subexpression....
| |
| 62 options.add(Flags.verbose); | 62 options.add(Flags.verbose); |
|
eernst
2016/04/12 12:10:47
If `arguments.contains(Flags.verbose)`, wouldn't `
Johnni Winther
2016/04/12 12:38:36
Dooh ... continued.
| |
| 63 } | 63 } |
| 64 List<Uri> uriList = <Uri>[]; | 64 List<Uri> uriList = <Uri>[]; |
| 65 for (String arg in arguments) { | 65 for (String arg in arguments) { |
| 66 if (!arg.startsWith('-')) { | 66 if (!arg.startsWith('-')) { |
| 67 for (String line in new File(arg).readAsLinesSync()) { | 67 for (String line in new File(arg).readAsLinesSync()) { |
| 68 line = line.trim(); | 68 line = line.trim(); |
| 69 if (line.startsWith('Analyzing uri: ')) { | 69 if (line.startsWith('Analyzing uri: ')) { |
| 70 int filenameOffset = line.indexOf('tests/compiler/dart2js/'); | 70 int filenameOffset = line.indexOf('tests/compiler/dart2js/'); |
| 71 if (filenameOffset != -1) { | 71 if (filenameOffset != -1) { |
| 72 uriList.add(Uri.base.resolve( | 72 uriList.add(Uri.base.resolve( |
| (...skipping 18 matching lines...) Expand all Loading... | |
| 91 } | 91 } |
| 92 } | 92 } |
| 93 await analyze( | 93 await analyze( |
| 94 uriList, | 94 uriList, |
| 95 WHITE_LIST, | 95 WHITE_LIST, |
| 96 mode: AnalysisMode.URI, | 96 mode: AnalysisMode.URI, |
| 97 options: options, | 97 options: options, |
| 98 skipList: MESSAGE_SKIP_LIST); | 98 skipList: MESSAGE_SKIP_LIST); |
| 99 }); | 99 }); |
| 100 } | 100 } |
| OLD | NEW |