Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(1572)

Unified Diff: tests/compiler/dart2js/part_of_test.dart

Issue 2760923004: Eliminate multi-callback structure for LibraryLoader. (Closed)
Patch Set: . Created 3 years, 9 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: tests/compiler/dart2js/part_of_test.dart
diff --git a/tests/compiler/dart2js/part_of_test.dart b/tests/compiler/dart2js/part_of_test.dart
index d2e81d8e76b63b198057bcff4129d63560a1b6ae..9c7bfee0c742f5f9da3da6e82bde1a8a243a1ef5 100644
--- a/tests/compiler/dart2js/part_of_test.dart
+++ b/tests/compiler/dart2js/part_of_test.dart
@@ -25,17 +25,19 @@ void main() {
compiler.registerSource(libraryUri, LIBRARY_SOURCE);
compiler.registerSource(partUri, PART_SOURCE);
- asyncTest(() => compiler.libraryLoader.loadLibrary(libraryUri).then((_) {
- DiagnosticCollector collector = compiler.diagnosticCollector;
- print('errors: ${collector.errors}');
- print('warnings: ${collector.warnings}');
- Expect.isTrue(collector.errors.isEmpty);
- Expect.equals(1, collector.warnings.length);
- Expect.equals(MessageKind.LIBRARY_NAME_MISMATCH,
- collector.warnings.first.messageKind);
- Expect.equals(
- 'foo',
- collector.warnings.first.message.arguments['libraryName']
- .toString());
- }));
+ asyncTest(
+ () => compiler.libraryLoader.loadLibrary(libraryUri).then((libraries) {
+ compiler.processLoadedLibraries(libraries);
+ DiagnosticCollector collector = compiler.diagnosticCollector;
+ print('errors: ${collector.errors}');
+ print('warnings: ${collector.warnings}');
+ Expect.isTrue(collector.errors.isEmpty);
+ Expect.equals(1, collector.warnings.length);
+ Expect.equals(MessageKind.LIBRARY_NAME_MISMATCH,
+ collector.warnings.first.messageKind);
+ Expect.equals(
+ 'foo',
+ collector.warnings.first.message.arguments['libraryName']
+ .toString());
+ }));
}

Powered by Google App Engine
This is Rietveld 408576698