| OLD | NEW |
| (Empty) | |
| 1 // Copyright (c) 2014, the Dart project authors. Please see the AUTHORS file |
| 2 // for details. All rights reserved. Use of this source code is governed by a |
| 3 // BSD-style license that can be found in the LICENSE file. |
| 4 |
| 5 import "dart:async"; |
| 6 import 'package:expect/expect.dart'; |
| 7 import 'package:async_helper/async_helper.dart'; |
| 8 |
| 9 // This library contains a member loadLibrary. |
| 10 // Check that we shadow this member. |
| 11 import "deferred_shadow_load_library_lib.dart" deferred as lib; |
| 12 |
| 13 void main() { |
| 14 var x = lib.loadLibrary(); |
| 15 Expect.isTrue(x is Future); |
| 16 asyncStart(); |
| 17 x.then((_) { |
| 18 Expect.isTrue(lib.trueVar); |
| 19 // Check that shadowing still is in place after loading the library. |
| 20 Expect.isTrue(lib.loadLibrary() is Future); |
| 21 asyncEnd(); |
| 22 }); |
| 23 } |
| OLD | NEW |