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

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

Issue 2243073002: Fix batch test as well. (Closed) Base URL: git@github.com:dart-lang/sdk.git@master
Patch Set: Fix batch test Created 4 years, 4 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
« no previous file with comments | « no previous file | tests/compiler/dart2js/launch_helper.dart » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: tests/compiler/dart2js/dart2js_batch_test.dart
diff --git a/tests/compiler/dart2js/dart2js_batch_test.dart b/tests/compiler/dart2js/dart2js_batch_test.dart
index 04b3ad670e4f65945b143607daa50470309a0faa..55f8ca77390da5e16203f43f724d12e6b745d6c6 100644
--- a/tests/compiler/dart2js/dart2js_batch_test.dart
+++ b/tests/compiler/dart2js/dart2js_batch_test.dart
@@ -10,6 +10,8 @@ import 'package:path/path.dart' as path;
import 'package:async_helper/async_helper.dart';
import 'package:expect/expect.dart';
+import 'launch_helper.dart' show dart2JsCommand;
+
var tmpDir;
copyDirectory(Directory sourceDir, Directory destinationDir) {
@@ -51,12 +53,11 @@ void cleanUp() {
}
Future launchDart2Js(_) {
- String ext = Platform.isWindows ? '.bat' : '';
- String command =
- path.normalize(path.join(path.fromUri(Platform.script),
- '../../../../sdk/bin/dart2js${ext}'));
- print("Running '$command --batch' from '${tmpDir}'.");
- return Process.start(command, ['--batch'], workingDirectory: tmpDir.path);
+ return Process.start(
+ // Use an absolute path because we are changing the cwd below.
+ path.fromUri(Uri.base.resolve(Platform.executable)),
+ dart2JsCommand(['--batch']),
+ workingDirectory: tmpDir.path);
}
Future runTests(Process process) {
« no previous file with comments | « no previous file | tests/compiler/dart2js/launch_helper.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698