OLD | NEW |
(Empty) | |
| 1 // Copyright (c) 2015, 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 @initializeTracker |
| 5 library web_components.test.init_web_components_test; |
| 6 |
| 7 import 'package:unittest/html_config.dart'; |
| 8 import 'package:unittest/unittest.dart'; |
| 9 import 'package:initialize/initialize.dart' show LibraryIdentifier; |
| 10 import 'package:initialize/src/initialize_tracker.dart'; |
| 11 import 'package:web_components/web_components.dart'; |
| 12 |
| 13 const String importPath = 'my_import.html'; |
| 14 |
| 15 main() { |
| 16 useHtmlConfiguration(); |
| 17 |
| 18 test('can initialize scripts from html imports', () { |
| 19 return initWebComponents().then((_) { |
| 20 var expectedInitializers = [ |
| 21 const LibraryIdentifier( |
| 22 #web_components.test.deps.b, null, 'deps/b.dart'), |
| 23 const LibraryIdentifier( |
| 24 #web_components.test.deps.c, null, 'deps/c.html'), |
| 25 const LibraryIdentifier( |
| 26 #web_components.test.deps.a, null, 'deps/a.dart'), |
| 27 const LibraryIdentifier(#web_components.test.init_web_components_test, |
| 28 null, 'init_web_components_test.dart'), |
| 29 ]; |
| 30 expect(InitializeTracker.seen, expectedInitializers); |
| 31 }); |
| 32 }); |
| 33 } |
OLD | NEW |