mirror of
https://github.com/ziglang/zig.git
synced 2025-12-25 23:53:15 +00:00
fix 7665:
only add self exe path when testing
This commit is contained in:
parent
fb37c1b091
commit
3d151fbfc8
13
src/main.zig
13
src/main.zig
@ -1853,9 +1853,16 @@ fn buildOutputType(
|
||||
else => unreachable,
|
||||
}
|
||||
}
|
||||
try argv.appendSlice(&[_][]const u8{
|
||||
exe_path, self_exe_path,
|
||||
});
|
||||
// when testing pass the zig_exe_path to argv
|
||||
if (arg_mode == .zig_test)
|
||||
try argv.appendSlice(&[_][]const u8{
|
||||
exe_path, self_exe_path,
|
||||
})
|
||||
// when running just pass the current exe
|
||||
else
|
||||
try argv.appendSlice(&[_][]const u8{
|
||||
exe_path,
|
||||
});
|
||||
} else {
|
||||
for (test_exec_args.items) |arg| {
|
||||
if (arg) |a| {
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user