Index: tests/lib/mirrors/equality_test.dart |
diff --git a/tests/lib/mirrors/equality_test.dart b/tests/lib/mirrors/equality_test.dart |
index 77e724f08adf6fa3277e7ed04cf6963bea8c5de4..94c98561c342d7a69265028402d5e3fb61601fdd 100644 |
--- a/tests/lib/mirrors/equality_test.dart |
+++ b/tests/lib/mirrors/equality_test.dart |
@@ -24,6 +24,9 @@ class BadEqualityHash { |
int get hashCode => count++; |
} |
+typedef bool Predicate(Object o); |
+Predicate somePredicate; |
+ |
checkEquality(List<Map> equivalenceClasses) { |
for (var equivalenceClass in equivalenceClasses) { |
equivalenceClass.forEach((name, member) { |
@@ -117,6 +120,38 @@ main() { |
'thisLibrary.classes[#B]' : thisLibrary.classes[#B], |
'reflect(new B()).type' : reflect(new B()).type}, |
+ {'reflectClass(BadEqualityHash).methods[#==]' /// 02: ok |
+ : reflectClass(BadEqualityHash).methods[#==], /// 02: ok |
+ 'reflect(new BadEqualityHash()).type.methods[#==]' /// 02: ok |
+ : reflect(new BadEqualityHash()).type.methods[#==]}, /// 02: ok |
+ |
+ {'reflectClass(BadEqualityHash).methods[#==].parameters[0]' /// 02: ok |
+ : reflectClass(BadEqualityHash).methods[#==].parameters[0], /// 02: ok |
+ 'reflect(new BadEqualityHash()).type.methods[#==].parameters[0]' /// 02: ok |
+ : reflect(new BadEqualityHash()).type.methods[#==].parameters[0]}, /// 02: ok |
+ |
+ {'reflectClass(BadEqualityHash).variables[#count]' /// 02: ok |
+ : reflectClass(BadEqualityHash).variables[#count], /// 02: ok |
+ 'reflect(new BadEqualityHash()).type.variables[#count]' /// 02: ok |
+ : reflect(new BadEqualityHash()).type.variables[#count]}, /// 02: ok |
+ |
+ {'reflectType(Predicate)' : reflectType(Predicate), /// 02: ok |
+ 'thisLibrary.variables[#somePredicate].type' /// 02: ok |
+ : thisLibrary.variables[#somePredicate].type}, /// 02: ok |
+ |
+ {'reflectType(Predicate).referent' : reflectType(Predicate).referent, /// 02: ok |
+ 'thisLibrary.variables[#somePredicate].type.referent' /// 02: ok |
+ : thisLibrary.variables[#somePredicate].type.referent}, /// 02: ok |
+ |
+ {'reflectClass(A).typeVariables.single' /// 02: ok |
+ : reflectClass(A).typeVariables.single, /// 02: ok |
+ 'reflect(new A<int>()).type.originalDeclaration.typeVariables.single' /// 02: ok |
+ : reflect(new A<int>()).type.originalDeclaration.typeVariables.single}, /// 02: ok |
+ |
+ {'currentMirrorSystem()' : currentMirrorSystem()}, |
+ |
+ {'currentMirrorSystem().isolate' : currentMirrorSystem().isolate}, |
+ |
{'thisLibrary' : thisLibrary, |
'reflectClass(A).owner' : reflectClass(A).owner, |
'reflectClass(B).owner' : reflectClass(B).owner, |