import stringToHTML from "./stringToHTML"; describe("stringToHTML", () => { it("preserves inline onclick handlers used by lesson action buttons", () => { const body = stringToHTML( `
Go
`, ); const el = body.firstElementChild as HTMLElement | null; expect(el).not.toBeNull(); expect(el?.getAttribute("onclick")).toContain("location.href"); }); });