Link guide cards to checklists and refine Aniimo ability filters
All checks were successful
Deploy Sokko G / deploy (push) Successful in 17s
All checks were successful
Deploy Sokko G / deploy (push) Successful in 17s
This commit is contained in:
parent
b5901b31e3
commit
7b23a8601a
23 changed files with 193 additions and 51 deletions
|
|
@ -149,9 +149,16 @@ test("tabs, flip, matching variants and reset remain independent", async ({ page
|
|||
test("ability levels use independent native ranges and retain name constraints", async ({ page }) => {
|
||||
await page.goto(route);
|
||||
const abilities = section(page, "Compétences de logis");
|
||||
const carry = page.getByRole("slider", { name: "Porter — Niveau minimum" });
|
||||
const crafting = page.getByRole("slider", { name: "Artisanat — Niveau minimum" });
|
||||
const carry = page.locator("#aniimo-minimum-carry");
|
||||
const crafting = page.locator("#aniimo-minimum-crafting");
|
||||
await expect(abilities.getByRole("checkbox")).toHaveCount(0);
|
||||
await expect(abilities.getByRole("button", { name: "OU", exact: true })).toHaveCount(0);
|
||||
const minimumLevel = abilities.getByRole("button", { name: "Niveau minimum", exact: true });
|
||||
const exactLevel = abilities.getByRole("button", { name: "Niveau exact", exact: true });
|
||||
await expect(minimumLevel).toHaveAttribute("aria-pressed", "true");
|
||||
await expect(exactLevel).toHaveAttribute("aria-pressed", "false");
|
||||
await expect(carry).toHaveAccessibleName("Porter — Niveau minimum");
|
||||
await expect(crafting).toHaveAccessibleName("Artisanat — Niveau minimum");
|
||||
await expect(carry).toHaveValue("0");
|
||||
await expect(carry).toHaveAttribute("min", "0");
|
||||
await carry.focus();
|
||||
|
|
@ -165,7 +172,10 @@ test("ability levels use independent native ranges and retain name constraints",
|
|||
await crafting.press("ArrowRight");
|
||||
await expect(crafting).toHaveValue("2");
|
||||
await expect(crafting).toHaveCSS("outline-style", "solid");
|
||||
await abilities.getByRole("button", { name: "OU", exact: true }).click();
|
||||
await exactLevel.click();
|
||||
await expect(exactLevel).toHaveAttribute("aria-pressed", "true");
|
||||
await expect(minimumLevel).toHaveAttribute("aria-pressed", "false");
|
||||
await expect(carry).toHaveAccessibleName("Porter — Niveau exact");
|
||||
await expect(section(page, "Éléments").getByRole("button", { name: "ET", exact: true })).toHaveAttribute("aria-pressed", "true");
|
||||
await carry.press("Home");
|
||||
await crafting.press("Home");
|
||||
|
|
@ -173,6 +183,9 @@ test("ability levels use independent native ranges and retain name constraints",
|
|||
await expect(cards(page)).toHaveCount(88);
|
||||
await page.getByRole("searchbox").fill("does-not-exist");
|
||||
await expect(page.getByRole("heading", { name: "Aucun résultat" })).toBeVisible();
|
||||
await page.getByRole("button", { name: "Réinitialiser les filtres", exact: true }).click();
|
||||
await expect(minimumLevel).toHaveAttribute("aria-pressed", "true");
|
||||
await expect(exactLevel).toHaveAttribute("aria-pressed", "false");
|
||||
});
|
||||
|
||||
test("seven tabs support keyboard navigation and fall back after filtering", async ({ page }) => {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue