aboutsummaryrefslogtreecommitdiff
path: root/test/tests.zig
diff options
context:
space:
mode:
authorAndrew Kelley <superjoe30@gmail.com>2017-10-15 16:03:32 -0400
committerAndrew Kelley <superjoe30@gmail.com>2017-10-15 16:03:32 -0400
commitbb169a7b36a658ed463787655df54e3f59133d98 (patch)
tree773587c8f8d31ff2d892d37ad8bcc3f6e1d319a5 /test/tests.zig
parent1fe1e6eeaf2f6157133546d49be6b0e0c1da3dd3 (diff)
downloadzig-bb169a7b36a658ed463787655df54e3f59133d98.tar.gz
zig-bb169a7b36a658ed463787655df54e3f59133d98.zip
fix child process stdio piping behavior on windows
Diffstat (limited to 'test/tests.zig')
-rw-r--r--test/tests.zig14
1 files changed, 6 insertions, 8 deletions
diff --git a/test/tests.zig b/test/tests.zig
index 6b2727e075..8f767c0bad 100644
--- a/test/tests.zig
+++ b/test/tests.zig
@@ -557,7 +557,7 @@ pub const CompileErrorContext = struct {
%%io.stderr.printf("Test {}/{} {}...", self.test_index+1, self.context.test_index, self.name);
if (b.verbose) {
- printInvocation(b.zig_exe, zig_args.toSliceConst());
+ printInvocation(zig_args.toSliceConst());
}
const child = %%os.ChildProcess.init(zig_args.toSliceConst(), b.allocator);
@@ -625,10 +625,9 @@ pub const CompileErrorContext = struct {
}
};
- fn printInvocation(exe_path: []const u8, args: []const []const u8) {
- %%io.stderr.printf("{}", exe_path);
+ fn printInvocation(args: []const []const u8) {
for (args) |arg| {
- %%io.stderr.printf(" {}", arg);
+ %%io.stderr.printf("{} ", arg);
}
%%io.stderr.printf("\n");
}
@@ -826,7 +825,7 @@ pub const ParseCContext = struct {
%%io.stderr.printf("Test {}/{} {}...", self.test_index+1, self.context.test_index, self.name);
if (b.verbose) {
- printInvocation(b.zig_exe, zig_args.toSliceConst());
+ printInvocation(zig_args.toSliceConst());
}
const child = %%os.ChildProcess.init(zig_args.toSliceConst(), b.allocator);
@@ -895,10 +894,9 @@ pub const ParseCContext = struct {
}
};
- fn printInvocation(exe_path: []const u8, args: []const []const u8) {
- %%io.stderr.printf("{}", exe_path);
+ fn printInvocation(args: []const []const u8) {
for (args) |arg| {
- %%io.stderr.printf(" {}", arg);
+ %%io.stderr.printf("{} ", arg);
}
%%io.stderr.printf("\n");
}