From c14eb2b60e6bb242e9556eed1c7c770bda351fb3 Mon Sep 17 00:00:00 2001 From: Vignesh Natarajan Date: Sat, 14 Feb 2026 19:08:19 -0800 Subject: [PATCH] test (tui): cover assistant default-foreground theme behavior --- src/tui/theme/theme.test.ts | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) diff --git a/src/tui/theme/theme.test.ts b/src/tui/theme/theme.test.ts index 8bef3b19b..c466241af 100644 --- a/src/tui/theme/theme.test.ts +++ b/src/tui/theme/theme.test.ts @@ -7,7 +7,7 @@ const cliHighlightMocks = vi.hoisted(() => ({ vi.mock("cli-highlight", () => cliHighlightMocks); -const { markdownTheme } = await import("./theme.js"); +const { markdownTheme, theme } = await import("./theme.js"); const stripAnsi = (str: string) => str.replace(new RegExp(`${String.fromCharCode(27)}\\[[0-9;]*m`, "g"), ""); @@ -52,3 +52,10 @@ describe("markdownTheme", () => { }); }); }); + +describe("theme", () => { + it("keeps assistant text in terminal default foreground", () => { + expect(theme.assistantText("hello")).toBe("hello"); + expect(stripAnsi(theme.assistantText("hello"))).toBe("hello"); + }); +});