Skip to Content
Use casesRunning scans with E2E tests

Running scans with E2E tests

Use Case: Running Scans with E2E Tests

7edab12b-5ac8-454e-9ada-f1b2e55ff19d.png

Actors:

  • Frontend Developer
  • QA Engineer
  • CI/CD System

Context: Teams running automated end-to-end (E2E) tests want to ensure that accessibility issues are caught during functional test execution, without requiring a separate workflow.

Goal: Run accessibility scans in parallel with E2E tests so accessibility checks are embedded into the existing QA pipeline.

Preconditions:

  • Level CI is installed and configured in the project.
  • E2E testing framework (e.g., Cypress, Playwright, Selenium) is set up in the repository.
  • Repositories are connected to Level CI.

Scenario (Happy Path):

  1. The developer/QA triggers the E2E test suite through CI/CD.
  2. Level CI integrates with the test runner to scan rendered pages/components for accessibility violations.
  3. Accessibility issues are collected and matched against the project’s A11y Quality Gate rules.
  4. Results are reported:
    1. In the CI pipeline logs.
    2. As annotations in pull requests.
    3. In the Level CI reporting dashboard.
  5. If the Quality Gate fails, the CI job is marked as failed, preventing merges or deployments until issues are resolved.

Post-conditions:

  • Accessibility violations are flagged early in the QA cycle.
  • Developers receive immediate feedback within their existing E2E test workflow.
  • Teams enforce accessibility compliance consistently before release.

Benefits:

  • Shifts accessibility checks left into automated testing.
  • Reduces manual rework by catching issues early.
  • Provides a single workflow for both functional and accessibility testing.
Last updated on