OLD | NEW |
1 // Copyright (c) 2012, the Dart project authors. Please see the AUTHORS file | 1 // Copyright (c) 2012, the Dart project authors. Please see the AUTHORS file |
2 // for details. All rights reserved. Use of this source code is governed by a | 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. | 3 // BSD-style license that can be found in the LICENSE file. |
4 | 4 |
5 /** End-to-end tests for the [Compiler] API. */ | 5 /** End-to-end tests for the [Compiler] API. */ |
6 library compiler_test; | 6 library compiler_test; |
7 | 7 |
8 import 'package:html5lib/dom.dart'; | 8 import 'package:html5lib/dom.dart'; |
9 import 'package:unittest/unittest.dart'; | 9 import 'package:unittest/unittest.dart'; |
10 import 'package:unittest/vm_config.dart'; | 10 import 'package:unittest/vm_config.dart'; |
11 import 'package:web_components/src/compiler.dart'; | 11 import 'package:web_ui/src/compiler.dart'; |
12 import 'package:web_components/src/file_system.dart'; | 12 import 'package:web_ui/src/file_system.dart'; |
13 import 'package:web_components/src/file_system/path.dart'; | 13 import 'package:web_ui/src/file_system/path.dart'; |
14 import 'package:web_components/src/options.dart'; | 14 import 'package:web_ui/src/options.dart'; |
15 import 'testing.dart'; | 15 import 'testing.dart'; |
16 | 16 |
17 main() { | 17 main() { |
18 useVmConfiguration(); | 18 useVmConfiguration(); |
19 useMockMessages(); | 19 useMockMessages(); |
20 | 20 |
21 test('recursive dependencies', () { | 21 test('recursive dependencies', () { |
22 var compiler = createCompiler({ | 22 var compiler = createCompiler({ |
23 'index.html': '<head>' | 23 'index.html': '<head>' |
24 '<link rel="components" href="foo.html">' | 24 '<link rel="components" href="foo.html">' |
(...skipping 52 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
77 Future<String> readText(Path filename) { | 77 Future<String> readText(Path filename) { |
78 var path = filename.toString(); | 78 var path = filename.toString(); |
79 readCount[path] = readCount.putIfAbsent(path, () => 0) + 1; | 79 readCount[path] = readCount.putIfAbsent(path, () => 0) + 1; |
80 return new Future.immediate(_files[path]); | 80 return new Future.immediate(_files[path]); |
81 } | 81 } |
82 | 82 |
83 // Compiler doesn't call these | 83 // Compiler doesn't call these |
84 void writeString(Path outfile, String text) {} | 84 void writeString(Path outfile, String text) {} |
85 Future flush() {} | 85 Future flush() {} |
86 } | 86 } |
OLD | NEW |