| Index: tests/lib/mirrors/mirrors_reader_test.dart
|
| diff --git a/tests/lib/mirrors/mirrors_reader_test.dart b/tests/lib/mirrors/mirrors_reader_test.dart
|
| index 4cd7b8cfd109cb79dba0caaeef817703d2b120f0..1c69b07928ee73cbf9522572ed53de231b1c20ee 100644
|
| --- a/tests/lib/mirrors/mirrors_reader_test.dart
|
| +++ b/tests/lib/mirrors/mirrors_reader_test.dart
|
| @@ -32,13 +32,17 @@ class RuntimeMirrorsReader extends MirrorsReader {
|
| bool expectUnsupported(var receiver, String tag, UnsupportedError exception) {
|
| // [DeclarationMirror.location] is intentionally not supported in runtime
|
| // mirrors.
|
| - if (receiver is DeclarationMirror && tag == 'location') {
|
| - return true;
|
| - }
|
| +
|
| if (mirrorSystemType == '_LocalMirrorSystem') {
|
| // VM mirror system.
|
| + if (receiver is DeclarationMirror && tag == 'location') {
|
| + return receiver is! MethodMirror;
|
| + }
|
| } else if (mirrorSystemType == 'JsMirrorSystem') {
|
| // Dart2js runtime mirror system.
|
| + if (receiver is DeclarationMirror && tag == 'location') {
|
| + return true;
|
| + }
|
| }
|
| return false;
|
| }
|
|
|