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

Unified Diff: tests/lib/mirrors/parameter_metadata_test.dart

Issue 64793003: Update mirror tests for removed API. (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: . Created 7 years, 1 month 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 | « tests/lib/mirrors/operator_test.dart ('k') | tests/lib/mirrors/parameter_test.dart » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: tests/lib/mirrors/parameter_metadata_test.dart
diff --git a/tests/lib/mirrors/parameter_metadata_test.dart b/tests/lib/mirrors/parameter_metadata_test.dart
index fdb1fc61e586c39eaee3f100d5e367ff2f7a1333..9f49450ea4b53a630e9258ef2fc49c61c3212c09 100644
--- a/tests/lib/mirrors/parameter_metadata_test.dart
+++ b/tests/lib/mirrors/parameter_metadata_test.dart
@@ -32,24 +32,32 @@ class B {
main() {
ClassMirror cm = reflectClass(B);
+ MethodMirror mm;
- checkMetadata(cm.constructors[#B.foo].parameters[0], []);
+ mm = cm.declarations[#B.foo];
+ checkMetadata(mm.parameters[0], []);
- checkMetadata(cm.constructors[#B.bar].parameters[0], [m3, m2]);
- checkMetadata(cm.constructors[#B.bar].parameters[1], []);
+ mm = cm.declarations[#B.bar];
+ checkMetadata(mm.parameters[0], [m3, m2]);
+ checkMetadata(mm.parameters[1], []);
- checkMetadata(cm.methods[#baz].parameters[0], [m1]);
- checkMetadata(cm.methods[#baz].parameters[1], [m2]);
- checkMetadata(cm.methods[#baz].parameters[2], [m3]);
+ mm = cm.declarations[#baz];
+ checkMetadata(mm.parameters[0], [m1]);
+ checkMetadata(mm.parameters[1], [m2]);
+ checkMetadata(mm.parameters[2], [m3]);
- checkMetadata(cm.methods[#qux].parameters[0], []);
- checkMetadata(cm.methods[#qux].parameters[1], [m3, m2, m1]);
+ mm = cm.declarations[#qux];
+ checkMetadata(mm.parameters[0], []);
+ checkMetadata(mm.parameters[1], [m3, m2, m1]);
- checkMetadata(cm.methods[#quux].parameters[0], []);
- checkMetadata(cm.methods[#quux].parameters[1], []);
+ mm = cm.declarations[#quux];
+ checkMetadata(mm.parameters[0], []);
+ checkMetadata(mm.parameters[1], []);
- checkMetadata(cm.methods[#corge].parameters[0], [m1]);
- checkMetadata(cm.methods[#corge].parameters[1], [m2]);
+ mm = cm.declarations[#corge];
+ checkMetadata(mm.parameters[0], [m1]);
+ checkMetadata(mm.parameters[1], [m2]);
- checkMetadata(cm.setters[const Symbol('x=')].parameters[0], [m2]);
+ mm = cm.declarations[const Symbol('x=')];
+ checkMetadata(mm.parameters[0], [m2]);
}
« no previous file with comments | « tests/lib/mirrors/operator_test.dart ('k') | tests/lib/mirrors/parameter_test.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698