chore(e2e): check katex is rendered in ToC

This commit is contained in:
Elian Doran 2025-01-11 13:41:25 +02:00
parent b44f4e0f74
commit 1530a09dc8
No known key found for this signature in database
2 changed files with 4 additions and 0 deletions

View File

@ -25,6 +25,10 @@ test("Table of contents is displayed", async ({ page }) => {
await expect(rootList.locator("> ol").first().locator("> li").first()).toHaveText("Heading 1.1");
await expect(rootList.locator("> ol").first().locator("> li").nth(1)).toHaveText("Heading 1.2");
// Heading 2 has a Katex equation, check if it's rendered.
await expect(rootList.locator("> li").nth(1)).toContainText("Heading 2");
await expect(rootList.locator("> li").nth(1).locator(".katex")).toBeAttached();
await expect(rootList.locator("> ol")).toHaveCount(2);
await expect(rootList.locator("> ol").nth(1).locator("> li")).toHaveCount(2);
await expect(rootList.locator("> ol").nth(1).locator("> ol")).toHaveCount(1);

Binary file not shown.