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

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

Issue 2238073005: Fix http test (Closed) Base URL: git@github.com:dart-lang/sdk.git@master
Patch Set: 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 | « tests/compiler/dart2js/quarantined/http_test.dart ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: tests/compiler/dart2js/zero_termination_test.dart
diff --git a/tests/compiler/dart2js/zero_termination_test.dart b/tests/compiler/dart2js/zero_termination_test.dart
index 3d07b7d01f86beceb9399ff910f12c53f63979d5..7599bc57a8bd9fd2bdb4c8c92926047deec861b6 100644
--- a/tests/compiler/dart2js/zero_termination_test.dart
+++ b/tests/compiler/dart2js/zero_termination_test.dart
@@ -15,6 +15,8 @@ import 'package:async_helper/async_helper.dart';
import 'package:expect/expect.dart';
import 'package:path/path.dart' as path;
+import 'launch_helper.dart' show launchDart2Js;
+
Uri pathOfData = Platform.script;
Directory tempDir;
String outFilePath;
@@ -46,21 +48,6 @@ void cleanup() {
}
}
-Future launchDart2Js(args) {
- String dart2jsPath = path.normalize(
- path.join(path.fromUri(Platform.script),
- '../../../../pkg/compiler/lib/src/dart2js.dart'));
- List allArgs = [];
- if (Platform.packageRoot != null) {
- allArgs.add('--package-root=${Platform.packageRoot}');
- } else if (Platform.packageConfig != null) {
- allArgs.add('--packages=${Platform.packageConfig}');
- }
- allArgs.add(dart2jsPath);
- allArgs.addAll(args);
- return Process.run(Platform.executable, allArgs, stdoutEncoding: null);
-}
-
void check(ProcessResult result) {
Expect.notEquals(0, result.exitCode);
List<int> stdout = result.stdout;
@@ -79,7 +66,7 @@ Future testFile() async {
List<String> args = [inFilePath, "--out=" + outFilePath];
await cleanup();
- check(await launchDart2Js(args));
+ check(await launchDart2Js(args, noStdoutEncoding: true));
await cleanup();
}
@@ -91,7 +78,7 @@ Future serverRunning(HttpServer server) async {
server.listen(handleRequest);
try {
await cleanup();
- check(await launchDart2Js(args));
+ check(await launchDart2Js(args, noStdoutEncoding: true));
} finally {
await server.close();
await cleanup();
« no previous file with comments | « tests/compiler/dart2js/quarantined/http_test.dart ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698