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

Unified Diff: test/codegen/lib/mirrors/empty_test.dart

Issue 2265533002: Add mirrors tests (Closed) Base URL: https://github.com/dart-lang/dev_compiler.git@master
Patch Set: Created 4 years, 4 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 | « test/codegen/lib/mirrors/empty.dart ('k') | test/codegen/lib/mirrors/enum_test.dart » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: test/codegen/lib/mirrors/empty_test.dart
diff --git a/test/codegen/language/enum_is_keyword_test.dart b/test/codegen/lib/mirrors/empty_test.dart
similarity index 60%
copy from test/codegen/language/enum_is_keyword_test.dart
copy to test/codegen/lib/mirrors/empty_test.dart
index 2d24d94810ab6c41b7cc44c42d7a98d5116df763..506cdfbef3af725e005a3841000c65a9441b2f76 100644
--- a/test/codegen/language/enum_is_keyword_test.dart
+++ b/test/codegen/lib/mirrors/empty_test.dart
@@ -2,9 +2,10 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
-// Test that `enum` is considered a keyword and therefore invalid as the name of
-// declarations.
+import 'dart:mirrors';
+import 'empty.dart';
main() {
- var enum; /// 01: compile-time error
+ var empty = currentMirrorSystem().findLibrary(#empty);
+ print(empty.location); // Used to crash VM.
}
« no previous file with comments | « test/codegen/lib/mirrors/empty.dart ('k') | test/codegen/lib/mirrors/enum_test.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698