Zum Hauptinhalt springen
tsecurity.de LIVE
Echtzeit-Radar & Feeds
Alle RSS Feeds
👥 Community & Social
Windows Tipps & SecurityGarmin Cirqa im Test: Fitness-Tracker ohne Display(22.09.2026 um 10:30 Uhr)
Windows Tipps & SecuritySicher online bezahlen: 7 Methoden im Praxis-Check(22.09.2026 um 09:00 Uhr)
Sichere Programmierunghas_tokens: true is a boolean. 476 of 791 have no market behind them.(22.09.2026 um 10:00 Uhr)
Sichere ProgrammierungClaude Code Hooks – Safety Through Invariants(22.09.2026 um 10:04 Uhr)
Sichere ProgrammierungYour MCP Tool Just Returned a Secret. Did It Need To?(22.09.2026 um 10:05 Uhr)
Windows Tipps & SecurityGarmin Cirqa im Test: Fitness-Tracker ohne Display(22.09.2026 um 10:30 Uhr)
Windows Tipps & SecuritySicher online bezahlen: 7 Methoden im Praxis-Check(22.09.2026 um 09:00 Uhr)
Sichere Programmierunghas_tokens: true is a boolean. 476 of 791 have no market behind them.(22.09.2026 um 10:00 Uhr)
Sichere ProgrammierungClaude Code Hooks – Safety Through Invariants(22.09.2026 um 10:04 Uhr)
Sichere ProgrammierungYour MCP Tool Just Returned a Secret. Did It Need To?(22.09.2026 um 10:05 Uhr)
Intelligence View
⚡ tsecurity.de Intelligence

Accessibility audits with Playwright, Axe, and GitHub Actions

I recently given a talk at JS Poland Conference about one of my most favourite topics -> Improving Software Quality by utilising Continuous Integration. We usually use CI to lint the code, run unit tests, or check if our project was…

0
↗ Quelle (dev.to)
Reagiere als Erste:r — dein Feedback zählt!

I recently given a talk at JS Poland Conference about one of my most favourite topics -> Improving Software Quality by utilising Continuous Integration. We usually use CI to lint the code, run unit tests, or check if our project was build correctly. While certainly important, these things are rather simple and we can use Continuous Integration for much more complex tests.



In this artice, I will focus about using Playwright and Axe builder, triggered automatically in GitHub Actions CI to continuously audit Accessibility of our application.



Playwright and Axe



Enjoy!






🟢 How to use Playwright and Axe in CI?



Running Accessibility tests in Playwright does not differ that much from doing the normal E2E tests.



First, we need to instruct the Playwright to run the localhost application server before running the tests:




import { defineConfig } from '@playwright/test';

export default defineConfig({
webServer: {
command: 'npm run start',
url: 'http://127.0.0.1:3000',
reuseExistingServer: !process.env.CI,
},
});






Then, we can start writing our first A11Y test with Playwright:




import { test, expect } from '@playwright/test';
import AxeBuilder from '@axe-core/playwright'; // 1

test.describe('homepage', () => { // 2
test('should not have any automatically detectable accessibility issues', async ({ page }) => {
await page.goto('https://your-site.com/'); // 3

const accessibilityScanResults = await new AxeBuilder({ page }).analyze(); // 4

expect(accessibilityScanResults.violations).toEqual([]); // 5
});
});






Let's stop for a minute and explain each of the steps marked with numbers individually:




  1. Imports the @axe-core/playwright package

  2. Uses normal Playwright Test syntax to define a test case

  3. Uses normal Playwright syntax to navigate to the page under test

  4. Awaits AxeBuilder.analyze() to run the accessibility scan against the page

  5. Uses normal Playwright Test assertions to verify that there are no violations in the returned scan results



Apart from using the default preset of Axe, we can also customize it to check for certain WCAG violcations like A or AA like following:




test('should not have any automatically detectable WCAG A or AA violations', async ({ page }) => {
await page.goto('https://your-site.com/');

const accessibilityScanResults = await new AxeBuilder({ page })
.withTags(['wcag2a', 'wcag2aa', 'wcag21a', 'wcag21aa'])
.analyze();

expect(accessibilityScanResults.violations).toEqual([]);
});






If we run this test locally, we should see similar result:



Local Playwright Accessibility test



If you would like to learn more about accessibility testing in playwright, check out here.



Now finally, the last step is to add the logic of running this test to CI (which we probably already have if we are using Playwright):




name: Playwright Tests
on:
push:
branches: main
jobs:
test:
//
- name: Install dependencies
run: npm ci
- name: Install Playwright Browsers
run: npx playwright install --with-deps
- name: Run Playwright tests
run: npx playwright test






And that's it! You have now implemented Accessibility audits in your Continuous Integration pipeline. Nicely done!






📖 Learn more



If you would like to learn more about Vue, Nuxt, JavaScript or other useful technologies, checkout VueSchool by clicking this link or by clicking the image below:



Vue School Link



It covers most important concepts while building modern Vue or Nuxt applications that can help you in your daily work or side projects 😉






✅ Summary



Well done! You have just learned how to implement Accessibility audits in your CI Pipeline.



Take care and see you next time!



And happy coding as always 🖥️

Ähnliche Beiträge
🔍 Verwandte News

Auch interessante Nachrichten Accessibility audits with Playwright, Axe, and GitHub Actions

Thematisch verwandte Begriffe: Accessibility, audits, with, Playwright · 6 Treffer

Laden...

Videos werden geladen ...

Laden...

Beiträge werden geladen ...

Laden...

Videos werden geladen ...

Laden...

Beiträge werden geladen ...

Laden...

Videos werden geladen ...

Laden...

Beiträge werden geladen ...

Laden...

Videos werden geladen ...

Laden...

Beiträge werden geladen ...

Laden...

Videos werden geladen ...

Zum Aktualisieren ziehen
ZERO-DAY CVE-2026-59815 | Joplin is an open source note-taking and to-do application that organise…
Advisory →
TTS Reader • tsecurity.de Voice
tsecurity.de Icon
tsecurity.de App
Offline-Lesen, Eilmeldungen & 0ms Ladezeit

Installiere tsecurity.de direkt auf deinen Home-Bildschirm für das ultimative Vollbild-Magazinerlebnis ohne Browser-Leisten.

Nächster Beitrag
Themen-Radar & Intelligence Matrix
Echtzeit-Taxonomie nach Angriffsvektoren & Plattformen

tsecurity.de Live Threat Radar

🔴 LIVE RADAR
MONITORING
AKTIV
CVE-DATENBANK
LIVE
🔍
Community Radar & Live Chat
Sentinel Bot online • Live-Stream
Dein Cluster: Security Explorer
Match:
lädt…
Verbindung zum Community-Stream wird aufgebaut...
Bearbeitungsmodus — Senden überschreibt deine Nachricht
Community-Puls — was gerade passiert
lädt…
Aktivitäten deiner Analysten
lädt…
Neues Thema oder Eilmeldung einreichen

Reiche interessante Links, Zero-Days oder Debatten ein. Die Community entscheidet per Upvote über die Veröffentlichung.

Heiß diskutierte Einreichungen
🔖 Gespeicherte Artikel
📂 Keine gespeicherten Artikel vorhanden.
Zurück Ziehen Vor
Links: vorheriger Artikel Rechts: nächster Artikel unten: schließen
News NIS-2 Frühwarnung Tier-1 Intel ⏱️ 3 Min vor 10 Min
Artikeldaten werden geladen...

Zurück: vorheriger Vor: nächster
↗ Original-Quelle
Social Reaktionen Deine Reaktion zählt
Einstufung & Relevanz-Poll 0 Stimmen
In sozialen Netzwerken teilen 1-Klick