A11y Unlocked: Screen-Reader Automation Tests

This page summarizes the projects mentioned and recommended in the original post on dev.to

Our great sponsors
  • SurveyJS - Open-Source JSON Form Builder to Create Dynamic Forms Right in Your App
  • WorkOS - The modern identity platform for B2B SaaS
  • InfluxDB - Power Real-Time Data Analytics at Scale
  • guidepup-playwright

    Screen reader driver for Playwright tests.

  • View on GitHub

  • guidepup

    Screen reader driver for test automation.

  • // We use a special test instance from the Guidepup package // that gives us access to VoiceOver! import { voTest as test } from "@guidepup/playwright"; import { expect } from "@playwright/test"; // The test setup is exactly the same as normal for // Playwright, expect we now get a `voiceOver` object as well // as the `page` object! test.describe("Playwright VoiceOver", () => { test("I can navigate the Guidepup Github page", async ({ page, voiceOver, }) => { // Let's navigate to Guidepup GitHub page and wait for // page to be ready, nothing special here! await page.goto("https://github.com/guidepup/guidepup", { waitUntil: "domcontentloaded", }); await expect( page.locator('header[role="banner"]') ).toBeVisible(); // This is where things start to get awesome! Let's tell // VoiceOver to interact with the main page content, just // the same as you would when use VoiceOver normally. await voiceOver.interact(); // Let's do something a lil more exciting - move across // the page's headings until we reach the main Guidepup // repo title in the README using VoiceOver! while ((await voiceOver.itemText()) !== "Guidepup heading level 1") { await voiceOver.perform( voiceOver.keyboard.commands.findNextHeading ); } });

  • SurveyJS

    Open-Source JSON Form Builder to Create Dynamic Forms Right in Your App. With SurveyJS form UI libraries, you can build and style forms in a fully-integrated drag & drop form builder, render them in your JS app, and store form submission data in any backend, inc. PHP, ASP.NET Core, and Node.js.

    SurveyJS logo
  • setup

    Setup your environment for screen reader test automation. (by guidepup)

  • You can head over to the Guidepup environment setup docs for more details, but I recommend trying out the @guidepup/setup package which is designed to get you setup no faff!

NOTE: The number of mentions on this list indicates mentions on common posts plus user suggested alternatives. Hence, a higher number means a more popular project.

Suggest a related project

Related posts