graff — a fast agentic coding harness in Zig: multi-provider, MCP, workflows, DGM evolution loop, TS/Python SDKs
Python
fix: build #830 title wrap fixtures without ** next to ++
Rachd1a9072e7714
diff --git a/src/session_tests.zig b/src/session_tests.zigindex af8ee311..26aa9fea 100644--- a/src/session_tests.zig+++ b/src/session_tests.zig@@ -146,18 +146,29 @@ test "#830 title preserves UTF-8 at the 80-byte boundary" {const a = arena_state.allocator();var root: Agent = undefined;root.session_title = null;+ const As = struct {+ fn get(comptime n: usize) [n]u8 {+ var buf: [n]u8 = undefined;+ @memset(&buf, 'a');+ return buf;+ }+ };+ const a76 = As.get(76);+ const a77 = As.get(77);+ const a78 = As.get(78);+ const a79 = As.get(79);const cases = .{- .{ "a" ** 78 ++ "é" ++ "suffix", "a" ** 78 ++ "é" },- .{ "a" ** 79 ++ "é" ++ "suffix", "a" ** 79 },- .{ "a" ** 77 ++ "界" ++ "suffix", "a" ** 77 ++ "界" },- .{ "a" ** 78 ++ "界" ++ "suffix", "a" ** 78 },- .{ "a" ** 76 ++ "🎉" ++ "suffix", "a" ** 76 ++ "🎉" },- .{ "a" ** 79 ++ "🎉" ++ "suffix", "a" ** 79 },+ .{ a78 ++ "é" ++ "suffix", a78 ++ "é" },+ .{ a79 ++ "é" ++ "suffix", a79 },+ .{ a77 ++ "界" ++ "suffix", a77 ++ "界" },+ .{ a78 ++ "界" ++ "suffix", a78 },+ .{ a76 ++ "🎉" ++ "suffix", a76 ++ "🎉" },+ .{ a79 ++ "🎉" ++ "suffix", a79 },};inline for (cases) |case| {root.messages = (try std.json.parseFromSliceLeaky(Value, a, "[{\"role\":\"user\",\"content\":[{\"type\":\"input_text\",\"text\":\" " ++ case[0] ++ " \"}]}]", .{})).array;const title = session.sessionTitle(&root);- try std.testing.expectEqualStrings(case[1], title);+ try std.testing.expectEqualStrings(case[1][0..], title);try std.testing.expect(std.unicode.utf8ValidateSlice(title));}}