| ... | @@ -585,16 +585,7 @@ pub fn addCases(cases: *tests.CompareOutputContext) void { | ... | @@ -585,16 +585,7 @@ pub fn addCases(cases: *tests.CompareOutputContext) void { |
| 585 | \\ comptime format: []const u8, | 585 | \\ comptime format: []const u8, |
| 586 | \\ args: anytype, | 586 | \\ args: anytype, |
| 587 | \\) void { | 587 | \\) void { |
| 588 | \\ const level_txt = switch (level) { | 588 | \\ const level_txt = comptime level.asText(); |
| 589 | \\ .emerg => "emergency", | | |
| 590 | \\ .alert => "alert", | | |
| 591 | \\ .crit => "critical", | | |
| 592 | \\ .err => "error", | | |
| 593 | \\ .warn => "warning", | | |
| 594 | \\ .notice => "notice", | | |
| 595 | \\ .info => "info", | | |
| 596 | \\ .debug => "debug", | | |
| 597 | \\ }; | | |
| 598 | \\ const prefix2 = if (scope == .default) ": " else "(" ++ @tagName(scope) ++ "): "; | 589 | \\ const prefix2 = if (scope == .default) ": " else "(" ++ @tagName(scope) ++ "): "; |
| 599 | \\ const stdout = std.io.getStdOut().writer(); | 590 | \\ const stdout = std.io.getStdOut().writer(); |
| 600 | \\ nosuspend stdout.print(level_txt ++ prefix2 ++ format ++ "\n", args) catch return; | 591 | \\ nosuspend stdout.print(level_txt ++ prefix2 ++ format ++ "\n", args) catch return; |
| ... | @@ -638,16 +629,7 @@ pub fn addCases(cases: *tests.CompareOutputContext) void { | ... | @@ -638,16 +629,7 @@ pub fn addCases(cases: *tests.CompareOutputContext) void { |
| 638 | \\ comptime format: []const u8, | 629 | \\ comptime format: []const u8, |
| 639 | \\ args: anytype, | 630 | \\ args: anytype, |
| 640 | \\) void { | 631 | \\) void { |
| 641 | \\ const level_txt = switch (level) { | 632 | \\ const level_txt = comptime level.asText(); |
| 642 | \\ .emerg => "emergency", | | |
| 643 | \\ .alert => "alert", | | |
| 644 | \\ .crit => "critical", | | |
| 645 | \\ .err => "error", | | |
| 646 | \\ .warn => "warning", | | |
| 647 | \\ .notice => "notice", | | |
| 648 | \\ .info => "info", | | |
| 649 | \\ .debug => "debug", | | |
| 650 | \\ }; | | |
| 651 | \\ const prefix2 = if (scope == .default) ": " else "(" ++ @tagName(scope) ++ "): "; | 633 | \\ const prefix2 = if (scope == .default) ": " else "(" ++ @tagName(scope) ++ "): "; |
| 652 | \\ const stdout = std.io.getStdOut().writer(); | 634 | \\ const stdout = std.io.getStdOut().writer(); |
| 653 | \\ nosuspend stdout.print(level_txt ++ prefix2 ++ format ++ "\n", args) catch return; | 635 | \\ nosuspend stdout.print(level_txt ++ prefix2 ++ format ++ "\n", args) catch return; |