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

Unified Diff: tests/compiler/dart2js/kernel/compiler_helper.dart

Issue 2942863002: Compile and run Hello World! (Closed)
Patch Set: Rebased Created 3 years, 6 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/kernel/compiler_helper.dart
diff --git a/tests/compiler/dart2js/kernel/compiler_helper.dart b/tests/compiler/dart2js/kernel/compiler_helper.dart
index ba8ab72306547dd7f9f109c313a4eac01fbf0e93..bea95fa6639836a1aff9e21f19ed168810017445 100644
--- a/tests/compiler/dart2js/kernel/compiler_helper.dart
+++ b/tests/compiler/dart2js/kernel/compiler_helper.dart
@@ -139,11 +139,8 @@ class MemoryDillLibraryLoaderTask extends DillLibraryLoaderTask {
}
}
-Future<Compiler> compileWithDill(
- Uri entryPoint, Map<String, String> memorySourceFiles, List<String> options,
- {bool printSteps: false,
- CompilerOutput compilerOutput,
- void beforeRun(Compiler compiler)}) async {
+Future createTemp(Uri entryPoint, Map<String, String> memorySourceFiles,
+ {bool printSteps: false}) async {
if (memorySourceFiles.isNotEmpty) {
Directory dir = await Directory.systemTemp.createTemp('dart2js-with-dill');
if (printSteps) {
@@ -166,6 +163,16 @@ Future<Compiler> compileWithDill(
'--platform=$buildDir/$configuration/patched_dart2js_sdk/platform.dill',
'$entryPoint'
]);
+ return dillFile;
+}
+
+Future<Compiler> compileWithDill(
+ Uri entryPoint, Map<String, String> memorySourceFiles, List<String> options,
+ {bool printSteps: false,
+ CompilerOutput compilerOutput,
+ void beforeRun(Compiler compiler)}) async {
+ Uri dillFile =
+ await createTemp(entryPoint, memorySourceFiles, printSteps: printSteps);
if (printSteps) {
print('---- compile from dill $dillFile ---------------------------------');
« no previous file with comments | « tests/compiler/dart2js/kernel/compile_from_dill_test.dart ('k') | tests/compiler/dart2js/kernel/run_from_dill_test.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698