Index: tests/lib/mirrors/return_type_test.dart |
diff --git a/tests/lib/mirrors/return_type_test.dart b/tests/lib/mirrors/return_type_test.dart |
index 6b90061cc8325bc9dde6a04dd3b1123e98693a6f..547e7610fb2e1fb97045d3482deacf643e24d75f 100644 |
--- a/tests/lib/mirrors/return_type_test.dart |
+++ b/tests/lib/mirrors/return_type_test.dart |
@@ -20,8 +20,16 @@ class B { |
// List<int> j() {} |
} |
+methodsOf(ClassMirror cm) { |
+ var result = new Map(); |
+ cm.declarations.forEach((k,v) { |
+ if(v is MethodMirror && v.isRegularMethod) result[k] = v; |
+ }); |
+ return result; |
+} |
+ |
main() { |
- var methods = reflectClass(B).methods; |
+ var methods = methodsOf(reflectClass(B)); |
expect('{f: Method(s(f) in s(B)), ' |
'g: Method(s(g) in s(B)), ' |
@@ -37,6 +45,4 @@ main() { |
expect('Class(s(int) in s(dart.core), top-level)', g.returnType); |
expect('Class(s(List) in s(dart.core), top-level)', h.returnType); |
expect('Class(s(B) in s(test.return_type_test), top-level)', i.returnType); |
- |
- print(methods); |
} |