"),
"Should render HTML-like tags or their content as text, not hide them",
);
});
it("should render HTML tags in code blocks correctly", () => {
const markdown = new Markdown(
"```html\nSome HTML
\n```",
0,
0,
defaultMarkdownTheme,
);
const lines = markdown.render(80);
const plainLines = lines.map((line) =>
line.replace(/\x1b\[[0-9;]*m/g, ""),
);
const joinedPlain = plainLines.join("\n");
// HTML in code blocks should be visible
assert.ok(
joinedPlain.includes("") && joinedPlain.includes("
"),
"Should render HTML in code blocks",
);
});
});
});