
This covers the essentials for testing web accessibility compliance, with examples for axe-core integration in Playwright, Cypress, and Jest. You get keyboard navigation tests, ARIA validation, and WCAG 2.1/2.2 checks. The best practices section is honest about automated testing only catching 30-40% of issues, so you'll still need manual testing and real screen readers. Use this when you need to validate WCAG AA compliance or test color contrast, focus management, and screen reader compatibility. The reference guides show actual test implementations rather than just theory, which makes it immediately useful for setting up CI checks.
$ npx -y skills add aj-geddes/useful-ai-prompts --skill accessibility-testing --agent claude-codeInstalls into .claude/skills of the current project.
Accessibility testing ensures web applications are usable by people with disabilities, including those using screen readers, keyboard navigation, or other assistive technologies. It validates compliance with WCAG (Web Content Accessibility Guidelines) and identifies barriers to accessibility.
Minimal working example:
// tests/accessibility/homepage.a11y.test.ts
import { test, expect } from "@playwright/test";
import AxeBuilder from "@axe-core/playwright";
test.describe("Homepage Accessibility", () => {
test("should not have any automatically detectable WCAG A or AA violations", async ({
page,
}) => {
await page.goto("/");
Sponsors