-
Notifications
You must be signed in to change notification settings - Fork 3
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
fix: missing accessibility labels and tests
Signed-off-by: rare-magma <[email protected]>
- Loading branch information
1 parent
a27bccf
commit b4c7642
Showing
4 changed files
with
45 additions
and
13 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,25 @@ | ||
import { expect, test } from "@playwright/test"; | ||
import { AxeBuilder } from "@axe-core/playwright"; | ||
|
||
test("should not have any automatically detectable accessibility issues on landing page", async ({ | ||
page, | ||
}) => { | ||
await page.goto("/"); | ||
const accessibilityScanResults = await new AxeBuilder({ page }) | ||
.disableRules("color-contrast") | ||
.analyze(); | ||
|
||
expect(accessibilityScanResults.violations).toStrictEqual([]); | ||
}); | ||
|
||
test("should not have any automatically detectable accessibility issues", async ({ | ||
page, | ||
}) => { | ||
await page.goto("/"); | ||
await page.getByText("get started").click(); | ||
const accessibilityScanResults = await new AxeBuilder({ page }) | ||
.disableRules("color-contrast") | ||
.analyze(); | ||
|
||
expect(accessibilityScanResults.violations).toStrictEqual([]); | ||
}); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters