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

Unified Diff: pkg/front_end/test/src/incremental/kernel_driver_test.dart

Issue 3009953003: Store actual Reference(s) for additional exports. (Closed)
Patch Set: Use references, but keep JSON hacks for errors and void/dynamic. Created 3 years, 3 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: pkg/front_end/test/src/incremental/kernel_driver_test.dart
diff --git a/pkg/front_end/test/src/incremental/kernel_driver_test.dart b/pkg/front_end/test/src/incremental/kernel_driver_test.dart
index f4de69e90973955076e8f452fa32414ce5f50d5d..d495e47c31dc44781e3c8cc3fd92e56d60a8418d 100644
--- a/pkg/front_end/test/src/incremental/kernel_driver_test.dart
+++ b/pkg/front_end/test/src/incremental/kernel_driver_test.dart
@@ -108,15 +108,31 @@ static method main() → void {}
String aPath = '/test/lib/a.dart';
String bPath = '/test/lib/b.dart';
String cPath = '/test/lib/c.dart';
+ String dPath = '/test/lib/d.dart';
writeFile(aPath, 'class A {}');
- writeFile(bPath, 'export "a.dart";');
- Uri cUri = writeFile(cPath, r'''
-import 'b.dart';
+ Uri bUri = writeFile(bPath, 'export "a.dart";');
+ Uri cUri = writeFile(cPath, 'export "b.dart";');
+ Uri dUri = writeFile(dPath, r'''
+import 'c.dart';
A a;
''');
- KernelResult result = await driver.getKernel(cUri);
- Library library = _getLibrary(result, cUri);
+ KernelResult result = await driver.getKernel(dUri);
+ Library library = _getLibrary(result, dUri);
+ expect(_getLibraryText(_getLibrary(result, bUri)), r'''
+library;
+import self as self;
+import "./a.dart" as a;
+additionalExports = (a::A)
+
+''');
+ expect(_getLibraryText(_getLibrary(result, cUri)), r'''
+library;
+import self as self;
+import "./a.dart" as a;
+additionalExports = (a::A)
+
+''');
expect(_getLibraryText(library), r'''
library;
import self as self;

Powered by Google App Engine
This is Rietveld 408576698