| Index: tests/lib/mirrors/libraries_test.dart
|
| diff --git a/tests/lib/mirrors/libraries_test.dart b/tests/lib/mirrors/libraries_test.dart
|
| index 1fd5d33bc1c405d9d5d71a0a1eab6341844331d3..f754c193ac0d12395fde0d254c668acb381ca4af 100644
|
| --- a/tests/lib/mirrors/libraries_test.dart
|
| +++ b/tests/lib/mirrors/libraries_test.dart
|
| @@ -15,8 +15,17 @@ main() {
|
| Map<Uri, LibraryMirror> libraries = mirrors.libraries;
|
| Expect.isNotNull(libraries, 'libraries is null');
|
|
|
| + Expect.isTrue(libraries.isNotEmpty);
|
| LibraryMirror mirrorsLibrary = libraries[Uri.parse('dart:mirrors')];
|
| - Expect.isNotNull(mirrorsLibrary, 'mirrorsLibrary is null');
|
| + if (mirrorsLibrary == null) {
|
| + // In minified mode we don't preserve the URIs.
|
| + mirrorsLibrary = libraries.values
|
| + .firstWhere((LibraryMirror lm) => lm.simpleName == #dart.mirrors);
|
| + Uri uri = mirrorsLibrary.uri;
|
| + Expect.equals("https", uri.scheme);
|
| + Expect.equals("dartlang.org", uri.host);
|
| + Expect.equals("/dart2js-stripped-uri", uri.path);
|
| + }
|
|
|
| ClassMirror cls = mirrorsLibrary.declarations[#LibraryMirror];
|
| Expect.isNotNull(cls, 'cls is null');
|
|
|