Skip to content

chore(a11y): add automated axe-core accessibility CI workflow - #654

Draft
stijnmoreels wants to merge 6 commits into
mainfrom
chore/add-accessibility-axe-workflow
Draft

chore(a11y): add automated axe-core accessibility CI workflow#654
stijnmoreels wants to merge 6 commits into
mainfrom
chore/add-accessibility-axe-workflow

Conversation

@stijnmoreels

@stijnmoreels stijnmoreels commented Jul 24, 2026

Copy link
Copy Markdown
Collaborator

Adds an automated accessibility check so WCAG/manual audits don't have to be repeated by hand each time.

  • .github/workflows/accessibility.yml: runs on push/PR to master/main, following the existing \doc-tests.yml\ conventions (pnpm/action-setup + npm install + start-server-and-test).
  • \cypress/e2e/accessibility.cy.js: uses \cypress-axe\ to scan one representative page per template (home, a standard doc page, a deprecated-content page, a migration guide, and the interactive release-notes filter/collapse widgets) against WCAG 2.0/2.1/2.2 A/AA rules (including the 2.2 touch-target-size rule). Fails only on critical/serious violations.
  • \cypress.config.js: added a \log\ task so violation details print to the CI console.

Adds a Cypress-based accessibility check (cypress-axe) that scans a
representative page per template (home, a standard doc page, a
deprecated-content page, a migration guide, and the interactive
release-notes filter/collapse widgets) against WCAG 2.0/2.1/2.2 A/AA
rules, failing the build only on critical/serious violations.

Runs on push/PR to master/main via .github/workflows/accessibility.yml,
following the existing doc-tests.yml conventions (pnpm/action-setup +
npm install + start-server-and-test).

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
@netlify

netlify Bot commented Jul 24, 2026

Copy link
Copy Markdown

Deploy Preview for invictus-for-azure ready!

Name Link
🔨 Latest commit f9c27fe
🔍 Latest deploy log https://app.netlify.com/projects/invictus-for-azure/deploys/6a7c248c7a911500084e867b
😎 Deploy Preview https://deploy-preview-654--invictus-for-azure.netlify.app
📱 Preview on mobile
Toggle QR Code...

QR Code

Use your smartphone camera to open QR code link.
🤖 Make changes Run an agent on this branch

To edit notification comments on pull requests, go to your Netlify project configuration.

stijnmoreels and others added 5 commits July 24, 2026 09:18
The general doc-tests.yml workflow runs 'npm run test' -> cy:run ->
'cypress run' with no --spec filter, which auto-discovers every spec
in cypress/e2e/, including the new accessibility.cy.js. That meant the
axe-core scan was running twice per PR (once in doc-tests.yml, once in
the dedicated accessibility.yml) and would also fail the general
doc-tests build on any a11y violation, which isn't its job.

- Move the accessibility spec into its own cypress/e2e/accessibility/
  subfolder so it's clearly separated from the functional specs.
- Scope the 'cy:run' npm script (used by doc-tests.yml) to
  'cypress/e2e/*.cy.js' (top-level only), so it only picks up the
  5 functional specs and skips the accessibility subfolder.
- accessibility.yml continues to target the spec directly via its
  own explicit --spec path, unaffected by the cy:run scoping.

Verified locally: 'npm run cy:run' picks up only the 5 functional
specs (137/137 passing) and skips accessibility.cy.js entirely;
running the accessibility spec directly via its new path still works
and correctly flags the known/deferred SearchBar contrast issue.

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant