a11y-playwright-testin…
Accessibility testing for web applications using Playwright (@playwright/test), TypeScript, and axe-core. Use to write, run, or debug WCAG 2.2 AA checks,…
Accessibility testing toolkit using Selenium WebDriver 4+ with Java 21+ and axe-core engine. Use when asked to validate WCAG 2.2 AA compliance, scan pages or components for a11y violations, test keyboard navigation, audit color contrast, check ARIA semantics, generate
$ npx -y skills add fugazi/test-automation-skills-agents --skill accessibility-selenium-testing --agent claude-codeHow it fires
How this skill gets triggered: by you, by Claude, or both.
/accessibility-selenium-testingContext preview
The summary Claude sees to decide when to auto-load this skill.
Accessibility testing toolkit using Selenium WebDriver 4+ with Java 21+ and axe-core engine. Use when asked to validate WCAG 2.2 AA compliance, scan pages or components for a11y violations, test keyboard navigation, audit color contrast, check ARIA semantics, generate
name: accessibility-selenium-testing description: 'Accessibility testing toolkit using Selenium WebDriver 4+ with Java 21+ and axe-core engine. Use when asked to validate WCAG 2.2 AA compliance, scan pages or components for a11y violations, test keyboard navigation, audit color contrast, check ARIA semantics, generate accessibility reports, filter axe rules, debug screen reader issues, or implement POUR principles (perceivable, operable, understandable, robust).' license: 'Complete terms in LICENSE.txt'
This skill enables automated accessibility analysis within the Selenium WebDriver framework using the **axe-core** engine to detect WCAG violations and best practice issues directly in the browser.
> **Activation:** This skill is triggered when you need to validate WCAG compliance, scan for accessibility violations, test keyboard navigation, audit ARIA semantics, or generate a11y reports.
| Component | Version | Purpose | |-----------|---------|---------| | Java JDK | 21+ | Runtime with modern features | | Maven | 3.9+ | Dependency management | | Selenium WebDriver | 4.x | Browser automation | | axe-core-selenium | 4.10+ | Deque axe-core integration | | JUnit 5 | 5.10+ | Test framework | | AssertJ | 3.x | Fluent assertions for readable failures | | Allure | 2.x | Reporting with a11y violation attachments |
> **Note:** Use `com.deque.html.axe-core:selenium` Maven dependency for axe integration.
---
> **Target:** WCAG 2.2 AA (`wcag2a`, `wcag2aa`, `wcag21a`, `wcag21aa`, `wcag22a`, `wcag22aa`). See [WCAG 2.2 spec](https://www.w3.org/TR/WCAG22/).
| Method | Purpose | Example | |--------|---------|---------| | `new AxeBuilder()` | Create scanner instance | Entry point | | `.withTags(List<String>)` | Filter by WCAG tags | `wcag2aa`, `wcag21aa`, `wcag22aa` | | `.include(String)` | Scan specific selector | `#main-content` | | `.exclude(String)` | Skip selector from scan | `.third-party-widget` | | `.disableRules(List<String>)` | Disable specific rules | `color-contrast` | | `.withRules(List<String>)` | Run only specific rules | `label`, `button-name` | | `.analyze(WebDriver)` | Execute the scan | Returns `Results` |
| Method | Returns | Purpose | |--------|---------|---------| | `getViolations()` | `List<Rule>` | Rules that failed | | `getPasses()` | `List<Rule>` | Rules that passed | | `getIncomplete()` | `List<Rule>` | Rules needing manual review | | `getInapplicable()` | `List<Rule>` | Rules not applicable to page | | `violationFree()` | `boolean` | True if no violations |
| Impact | Severity | CI Action | |--------|----------|-----------| | **Critical** | Blocks users completely | Always fail build | | **Serious** | Significant barrier | Always fail build | | **Moderate** | Some difficulty | Warn or fail | | **Minor** | Inconvenience | Log for review |
---
1. **Add dependency to pom.xml**
<dependency>
<groupId>com.deque.html.axe-core</groupId>
<artifactId>selenium</artifactId>
<version>4.10.0</version>
</dependency>2. **Create AccessibilityHelper utility**
3. **Add scan after page loads**
driver.get("https://example.com");
waitForPageReady();
AccessibilityHelper.verifyPageAccessibility(driver);4. **Run and review violations**
mvn test -Dtest=A11yTest
1. **Navigate to page with component visible** 2. **Trigger component state** (open modal, show dropdown) 3. **Scan only the component**
Results results = new AxeBuilder()
.withTags(List.of("wcag2a", "wcag2aa", "wcag22aa"))
.include("#login-modal")
.analyze(driver);4. **Assert and log**
1. **Identify all interactive elements** 2. **Tab through the page programmatically**
element.sendKeys(Keys.TAB); WebElement focused = driver.switchTo().activeElement();
3. **Verify focus order is logical** 4. **Test Escape closes modals** 5. **Verify no keyboard traps**
1. **Configure headless browser**
mvn test -Dheadless=true -Dgroups=a11y
2. **Set zero-tolerance for Critical/Serious**
long criticalCount = violations.stream()
.filter(v -> List.of("critical", "serious").contains(v.getImpact()))
.count();
assertThat(criticalCount).isZero();3. **Generate JSON report for tracking**
---
See [`references/code-patterns.md`](references/code-patterns.md) for full AxeBuilder scan patterns, violation logging, JUnit 5 integration, and CI/CD YAML.
Key snippet:
Results results = new AxeBuilder()
.withTags(List.of("wcag2a", "wcag2aa", "wcag21a", "wcag21aa", "wcag22a", "wcag22aa"))
.analyze(driver);
assertThat(results.violationFree()).as("A11y violations").isTrue();| Problem | Cause |
A practical library of agents, instructions, and skills designed specifically for QA Automation Engineers, focusing on production-oriented solutions.
Repo: fugazi/test-automation-skills-agents
Accessibility testing for web applications using Playwright (@playwright/test), TypeScript, and axe-core. Use to write, run, or debug WCAG 2.2 AA checks,…
Test REST and GraphQL endpoint contracts using Playwright request fixture (TypeScript) or REST Assured (Java). Use for standalone API tests covering schemas,…
A guided interview to challenge and validate QA automation plans, test strategies, and framework designs before implementation. Use when the user wants to…
Drive a live browser from the CLI with playwright-cli to navigate, interact, snapshot, and capture evidence. Use for ad-hoc browser commands, page inspection,…
Author and maintain versioned Playwright (@playwright/test) TypeScript UI specs for browser user flows. Use when asked to create, run, debug, or refactor E2E…
Govern Playwright TypeScript regression suites across many tests. Use when asked to plan, select, tier, execute, or optimize suites with risk/change analysis,…