v3 : C20, le cran actuel se clique sans être choisi (aria-disabled, l'automate envoie l'événement)

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
Yvv
2026-10-31 05:49:15 +01:00
co-authored by Claude Opus 5.5
parent 785580c78f
commit 25af01154a
+2 -1
View File
@@ -320,7 +320,8 @@ test('C20 — réglages de la formule et cinq crans', async ({ page }) => {
await expect(e2.locator('[role="radio"][tabindex="0"]')).toHaveCount(1);
await expect(levels.nth(3)).toHaveAttribute('tabindex', '0');
await expect(e2.getByText("Un changement d'inertie se vote lui-même à l'inertie de l'article : 4 / 5 · haute.")).toBeVisible();
await levels.nth(3).click();
// A click on it (Playwright refuses an aria-disabled target: the event is sent as is) chooses nothing.
await levels.nth(3).dispatchEvent('click');
await expect(e2.locator('[role="radio"][aria-checked="true"]')).toHaveCount(0);
// With the keyboard: the arrows go from level to level and choose it, wrapping round.
await levels.nth(3).focus();