From 4956668702f3e029b615a5600531eadc40170f9b Mon Sep 17 00:00:00 2001 From: Chris Marchesi Date: Tue, 21 Jul 2026 22:00:13 -0700 Subject: [PATCH] vt: get rid of log spam on tests Zig 0.16.0 made the criteria for reporting "failed command" stricter (or looser, depending on your perspective I guess...) - now, tests that print anything to stderr cause the message to appear. Note that in this instance tests still pass and you get a return code of 0, but nonetheless, it can be confusing. Additionally, having spammy passing tests in general is not necessarily a great experience, so this should help with that. Note that this change was already done to the main tests. We can add a build argument to control this if need be. --- src/lib_vt.zig | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/src/lib_vt.zig b/src/lib_vt.zig index 2475ff786..b4a2722bf 100644 --- a/src/lib_vt.zig +++ b/src/lib_vt.zig @@ -386,6 +386,12 @@ pub const std_options: std.Options = opts: { }; test { + // Zig 0.16.0 has made test logging more strict. Now, *anything* that gets + // printed to stderr results in a "failed command" message, even if the + // tests ultimately passed. To reduce confusion here (and honestly, test + // log spam in general), we bump the default testing log level to error. + @import("std").testing.log_level = std.log.Level.err; + _ = terminal; _ = @import("lib/main.zig"); @import("std").testing.refAllDecls(input);