Skip to content

Commit 976a537

Browse files
hellpanderrrclaude
andcommitted
test(macronizer): assert the content attribute — words render via CSS attr(content), textContent is empty
Verified against an instrumented run: the engine initializes (812,337 wordlist entries), macronizes provinciarum -> prōvinciārum, and renders it as <span class="ipa" content="prōvinciārum">. Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
1 parent 2d2b294 commit 976a537

1 file changed

Lines changed: 8 additions & 4 deletions

File tree

wiktionary_pron/e2e/macronizer.spec.js

Lines changed: 8 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -25,9 +25,13 @@ test.describe("macronizer", () => {
2525
await page.click("#macronize_btn");
2626

2727
await expect(page.locator("#result")).toBeVisible({ timeout: 120_000 });
28-
// prōvinciārum: gen.pl. of prōvincia — both long vowels must be marked
29-
await expect(page.locator("#resultText")).toContainText("prōvinciārum", {
30-
timeout: 120_000,
31-
});
28+
// prōvinciārum: gen.pl. of prōvincia — both long vowels must be marked.
29+
// Words render via a `content` attribute painted with CSS attr(content),
30+
// so the span's text is empty — assert the attribute, not the text.
31+
await expect(page.locator("#resultText .ipa").first()).toHaveAttribute(
32+
"content",
33+
"prōvinciārum",
34+
{ timeout: 120_000 },
35+
);
3236
});
3337
});

0 commit comments

Comments
 (0)