Jiahan Chen 20e3daaaca test(frontend): migrate unit tests to rstest (#3703)
* test(frontend): migrate unit tests to rstest

* docs: updates AGENTS.md

* test(frontend): fix rstest lint formatting
2026-06-23 22:40:10 +08:00

14 lines
446 B
TypeScript

import { expect, test } from "@rstest/core";
import rehypeRaw from "rehype-raw";
import { reasoningPlugins, streamdownPlugins } from "@/core/streamdown/plugins";
test("streamdownPlugins includes rehypeRaw", () => {
expect(streamdownPlugins.rehypePlugins).toContain(rehypeRaw);
});
test("reasoningPlugins does not include rehypeRaw", () => {
const flat = reasoningPlugins.rehypePlugins?.flat();
expect(flat).not.toContain(rehypeRaw);
});