import { describe, expect, it } from "vitest"; import { eslint } from "./lintProbe.testkit"; // `local/jsx-comment-text` (eslint.config.js): a `//` inside JSX children is rendered as text. One // reached the Playlists page past tsc, eslint and every test — only a visual check caught it. A rule // that matches nothing looks exactly like a clean codebase, so this asserts it fires. const RULE = "local/jsx-comment-text"; async function hits(source: string): Promise { const [result] = await eslint.lintText(source, { filePath: "src/components/__probe.tsx" }); return (result?.messages ?? []).filter((m) => m.ruleId === RULE).length; } describe("a comment inside JSX children", () => { it("is refused — it would render as text", async () => { expect( await hits(`export const A = () => (\n <>\n // the list\n