| ... | @@ -503,6 +503,7 @@ const usage_build_generic = | ... | @@ -503,6 +503,7 @@ const usage_build_generic = |
| 503 | \\ --test-cmd-bin Appends test binary path to test cmd args | 503 | \\ --test-cmd-bin Appends test binary path to test cmd args |
| 504 | \\ --test-evented-io Runs the test in evented I/O mode | 504 | \\ --test-evented-io Runs the test in evented I/O mode |
| 505 | \\ --test-no-exec Compiles test binary without running it | 505 | \\ --test-no-exec Compiles test binary without running it |
| | 506 | \\ --test-runner [path] Specify a custom test runner |
| 506 | \\ | 507 | \\ |
| 507 | \\Debug Options (Zig Compiler Development): | 508 | \\Debug Options (Zig Compiler Development): |
| 508 | \\ -ftime-report Print timing diagnostics | 509 | \\ -ftime-report Print timing diagnostics |
| ... | @@ -726,6 +727,7 @@ fn buildOutputType( | ... | @@ -726,6 +727,7 @@ fn buildOutputType( |
| 726 | var runtime_args_start: ?usize = null; | 727 | var runtime_args_start: ?usize = null; |
| 727 | var test_filter: ?[]const u8 = null; | 728 | var test_filter: ?[]const u8 = null; |
| 728 | var test_name_prefix: ?[]const u8 = null; | 729 | var test_name_prefix: ?[]const u8 = null; |
| | 730 | var test_runner_path: ?[]const u8 = null; |
| 729 | var override_local_cache_dir: ?[]const u8 = try optionalStringEnvVar(arena, "ZIG_LOCAL_CACHE_DIR"); | 731 | var override_local_cache_dir: ?[]const u8 = try optionalStringEnvVar(arena, "ZIG_LOCAL_CACHE_DIR"); |
| 730 | var override_global_cache_dir: ?[]const u8 = try optionalStringEnvVar(arena, "ZIG_GLOBAL_CACHE_DIR"); | 732 | var override_global_cache_dir: ?[]const u8 = try optionalStringEnvVar(arena, "ZIG_GLOBAL_CACHE_DIR"); |
| 731 | var override_lib_dir: ?[]const u8 = try optionalStringEnvVar(arena, "ZIG_LIB_DIR"); | 733 | var override_lib_dir: ?[]const u8 = try optionalStringEnvVar(arena, "ZIG_LIB_DIR"); |
| ... | @@ -1043,6 +1045,8 @@ fn buildOutputType( | ... | @@ -1043,6 +1045,8 @@ fn buildOutputType( |
| 1043 | test_filter = args_iter.nextOrFatal(); | 1045 | test_filter = args_iter.nextOrFatal(); |
| 1044 | } else if (mem.eql(u8, arg, "--test-name-prefix")) { | 1046 | } else if (mem.eql(u8, arg, "--test-name-prefix")) { |
| 1045 | test_name_prefix = args_iter.nextOrFatal(); | 1047 | test_name_prefix = args_iter.nextOrFatal(); |
| | 1048 | } else if (mem.eql(u8, arg, "--test-runner")) { |
| | 1049 | test_runner_path = args_iter.nextOrFatal(); |
| 1046 | } else if (mem.eql(u8, arg, "--test-cmd")) { | 1050 | } else if (mem.eql(u8, arg, "--test-cmd")) { |
| 1047 | try test_exec_args.append(args_iter.nextOrFatal()); | 1051 | try test_exec_args.append(args_iter.nextOrFatal()); |
| 1048 | } else if (mem.eql(u8, arg, "--cache-dir")) { | 1052 | } else if (mem.eql(u8, arg, "--cache-dir")) { |
| ... | @@ -2943,6 +2947,7 @@ fn buildOutputType( | ... | @@ -2943,6 +2947,7 @@ fn buildOutputType( |
| 2943 | .test_evented_io = test_evented_io, | 2947 | .test_evented_io = test_evented_io, |
| 2944 | .test_filter = test_filter, | 2948 | .test_filter = test_filter, |
| 2945 | .test_name_prefix = test_name_prefix, | 2949 | .test_name_prefix = test_name_prefix, |
| | 2950 | .test_runner_path = test_runner_path, |
| 2946 | .disable_lld_caching = !have_enable_cache, | 2951 | .disable_lld_caching = !have_enable_cache, |
| 2947 | .subsystem = subsystem, | 2952 | .subsystem = subsystem, |
| 2948 | .wasi_exec_model = wasi_exec_model, | 2953 | .wasi_exec_model = wasi_exec_model, |