Open-source Grok Bot alternative for named AI teammates. Local-first desktop, web, and mobile clients with per-bot tools, instructions, and memory. Independent fork of T3 Code.
import { describe, expect, it } from "vite-plus/test";
import { spokenTextDisclosure } from "./disclosure.ts";
import { replyMarkdownToSpokenText } from "./spokenText.ts";
describe("spoken text disclosure", () => {
it("explains skipped non-prose and empty or oversized replies", () => {
expect(
spokenTextDisclosure(
replyMarkdownToSpokenText("```ts\nsecret()\n```\n\n"),
),
).toBe("1 code block skipped. 1 image skipped.");
expect(spokenTextDisclosure(replyMarkdownToSpokenText(""))).toBe(
"This reply has no readable text.",
);
expect(spokenTextDisclosure(replyMarkdownToSpokenText("Hello"))).toBeUndefined();
});
});