From a8c4977ed8ede7076c04381df781fb8b02c8ea8d Mon Sep 17 00:00:00 2001 From: Pierre Tachoire Date: Thu, 28 Sep 2023 07:43:40 +0200 Subject: [PATCH] build: run test suite --- build.zig | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/build.zig b/build.zig index ed3f9e25..067a3c84 100644 --- a/build.zig +++ b/build.zig @@ -64,12 +64,14 @@ pub fn build(b: *std.build.Builder) !void { // ---- // compile - const exe_tests = b.addTest(.{ .root_source_file = .{ .path = "src/run_tests.zig" } }); - try common(exe_tests, options); + const tests = b.addTest(.{ .root_source_file = .{ .path = "src/run_tests.zig" } }); + try common(tests, options); + tests.single_threaded = true; + const run_tests = b.addRunArtifact(tests); // step const test_step = b.step("test", "Run unit tests"); - test_step.dependOn(&exe_tests.step); + test_step.dependOn(&run_tests.step); } fn common(