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

Unified Diff: tests/compiler/dart2js/analyze_only_test.dart

Issue 12431009: Add --analyze-signatures-only option to dart2js (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Updated cf. comments + test expanded Created 7 years, 10 months 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « sdk/lib/_internal/compiler/implementation/resolution/members.dart ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: tests/compiler/dart2js/analyze_only_test.dart
diff --git a/tests/compiler/dart2js/analyze_only_test.dart b/tests/compiler/dart2js/analyze_only_test.dart
index f17aed48b1d02be16c8c524e56c83e4e34c995f3..ffbc7a598fc6bc3ffb6f1454cd2565e4f91a216f 100644
--- a/tests/compiler/dart2js/analyze_only_test.dart
+++ b/tests/compiler/dart2js/analyze_only_test.dart
@@ -108,6 +108,17 @@ main() {
});
runCompiler(
+ """main() {
+ Foo foo; // Unresolved and analyzed.
+ }""",
+ ['--analyze-only', '--analyze-signatures-only'],
+ (String code, List errors, List warnings) {
+ Expect.isNull(code);
+ Expect.isTrue(errors.isEmpty);
+ Expect.isTrue(warnings.isEmpty);
+ });
+
+ runCompiler(
"Foo foo; // Unresolved and analyzed.",
['--analyze-only', '--analyze-all'],
(String code, List errors, List warnings) {
@@ -126,4 +137,23 @@ main() {
Expect.equals(1, warnings.length);
Expect.equals('Warning: cannot resolve type Foo', warnings[0].toString());
});
+
+ runCompiler(
+ "",
+ ['--analyze-only', '--analyze-all'],
+ (String code, List errors, List warnings) {
+ Expect.isNull(code);
+ Expect.isTrue(errors.isEmpty);
+ Expect.isTrue(warnings.isEmpty);
+ });
+
+ // --analyze-signatures-only implies --analyze-only
+ runCompiler(
+ "",
+ ['--analyze-signatures-only', '--analyze-all'],
+ (String code, List errors, List warnings) {
+ Expect.isNull(code);
+ Expect.isTrue(errors.isEmpty);
+ Expect.isTrue(warnings.isEmpty);
+ });
}
« no previous file with comments | « sdk/lib/_internal/compiler/implementation/resolution/members.dart ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698