QA Interview Hub · Knowledge base · Quizzes · Українська

QA Fundamentals › Types of testing

Accessibility testing in practice: WCAG 2.2 for a QA Engineer

Accessibility is checked against WCAG 2.2 in three layers: a scanner in CI, a manual pass (keyboard, text enlargement, field labels) and a screen reader. A scanner finds only what a rule can decide, so "0 errors" does not prove conformance. In the EU the European Accessibility Act (EAA) applies to products placed on the market after 28 June 2025 and to services provided after that date, existing ones included.

Manual QA · Accessibility

The scanner shows 0 errors, yet the dialog cannot be closed from the keyboard. Whose verdict counts?

A new payment page was checked with an automated scanner: 0 violations. A tester puts the mouse aside, presses Tab and sees that the "Pay" button is built from a div, focus never reaches it, and the card field has only a hint that disappears while typing. The scanner did not make a mistake: it checked what a rule can decide, and only a person checks the rest. This article is about how a QA Engineer tests accessibility against WCAG 2.2: what the requirements are, which checks to automate and which to do by hand, and why this became a legal question for the EU market.

How it is built and why. WCAG (Web Content Accessibility Guidelines) 2.2 became a W3C Recommendation on 5 October 2023 (the current edition is dated 12 December 2024). Requirements are written as success criteria with levels A, AA and AAA: the higher the level, the stricter the requirement. Version 2.2 is backwards compatible with 2.1: a page that conforms to 2.2 is at least as accessible as under 2.1. Criterion 4.1.1 Parsing was removed in 2.2 as obsolete. The criteria are worded so that they can be verified: each describes an outcome for the user, not a way to implement it. That is why the same criterion is checked both with a scanner (where the rule is unambiguous) and by hand (where judgement is needed).

The criteria a QA meets most often:

CriterionLevelWhat is checked
1.1.1 Non-text ContentAA text alternative for images
1.4.3 Contrast (Minimum)AA4.5:1 for text, 3:1 for large text
1.4.11 Non-text ContrastAA3:1 for interface components and states
2.1.1 KeyboardAEverything works from the keyboard
2.1.2 No Keyboard TrapAThe keyboard can leave the component
2.4.3 Focus OrderAFocus order preserves meaning
2.4.7 Focus VisibleAAFocus is visible
4.1.2 Name, Role, ValueAThe name and role of a component are programmatically determined

What 2.2 added. New criteria: 2.4.11 Focus Not Obscured (Minimum), AA: a focused element is not entirely hidden by author content, such as a sticky header or a cookie banner; 2.4.12 Focus Not Obscured (Enhanced) and 2.4.13 Focus Appearance, AAA; 2.5.7 Dragging Movements, AA: any dragging action can be done with a single pointer without dragging; 2.5.8 Target Size (Minimum), AA: pointer targets are at least 24 by 24 CSS pixels or have enough spacing; 3.2.6 Consistent Help, A: repeated help appears in the same order; 3.3.7 Redundant Entry, A: what was already entered in the same process is filled in or selectable; 3.3.8 Accessible Authentication (Minimum), AA: signing in does not require a cognitive test (remembering a password or solving a puzzle) without an alternative or assistance; 3.3.9 Accessible Authentication (Enhanced), AAA. For QA these are ready checklist items: a sticky header, drag-and-drop lists, small icons on mobile, sign-in forms where pasting a password works.

Three layers of checking. Automated. The axe-core scanner in CI catches regressions cheaply. With Playwright that is @axe-core/playwright; the documentation suggests limiting WCAG tags, and its list ends at wcag21aa, but axe-core also has a wcag22aa tag (WCAG 2.2 AA), so it is added for a 2.2 AA target, and which 2.2 criteria the rules of your version cover is checked separately. The scanner does not see closed modal windows until they are opened, and "needs review" (incomplete) results are looked at by hand. Manual pass. The quick W3C checks (Easy Checks): image alt text, page title, headings, contrast, a skip link, visible keyboard focus, page language, zoom, captions and transcripts, form labels and required fields. W3C itself says this is not a full evaluation. Screen reader and users. On key flows (sign-in, payment) you go through with a screen reader (NVDA, VoiceOver, TalkBack) and, if possible, with people who use one: only that shows whether the announcements are understandable.

Worked example: before and after. A fragment of the payment page that a scanner will partly miss or judge only by the presence of attributes:

<div class="btn" onclick="pay()">Сплатити</div>
<input placeholder="Номер картки">
<img src="limits.png">

Diagnosis. A div with onclick does not enter the Tab order and has no button role: 2.1.1 (keyboard) and 4.1.2 (name and role) are not met. A field without a label: the hint disappears as soon as the person types, and W3C in its quick checks advises making sure that every field has a label. An image without alt violates 1.1.1. The fix replaces custom elements with native ones:

<button type="button" onclick="pay()">Сплатити</button>
<label for="card">Номер картки</label>
<input id="card" inputmode="numeric">
<img src="limits.png" alt="Ліміти за картками">

A native button brings focus, the Enter and Space keys and the role, so it is more correct than adding tabindex and role to a div. The alt text describes the purpose of the image in context, while a purely decorative one is marked with an empty alt="". A regression of this kind is pinned with a test:

import AxeBuilder from '@axe-core/playwright';

test('pay page: keyboard and scan', async ({ page }) => {
  await page.goto('/pay');
  await page.keyboard.press('Tab');
  await expect(page.getByRole('button', { name: 'Сплатити' })).toBeFocused();
  const scan = await new AxeBuilder({ page })
    .withTags(['wcag2a', 'wcag2aa', 'wcag21a', 'wcag21aa', 'wcag22aa'])
    .analyze();
  expect(scan.violations).toEqual([]);
});

The first Tab lands on the button only if it is first in the order, so in a real page the number of presses is adapted to its structure. An empty violations array proves only that nothing was found automatically.

Limits. No set of checks proves full conformance: for a full evaluation W3C recommends the WCAG-EM methodology and involving users. If only the initial state was checked, dialogs, error messages, dropdown menus and post-action states stay unseen. Mobile apps have their own platform tools (the VoiceOver and TalkBack screen readers), although WCAG itself is written for the web.

Why this is now a legal question. The European Accessibility Act (EAA) applies to products placed on the EU market after 28 June 2025 and to services provided to consumers after that date, existing ones included (their transitional periods run until 28 June 2030). Covered are online shops, banking services, e-books, ATMs and ticketing services. A service business with fewer than 10 employees and a turnover under 2 million euros is exempt, and only for services; everyone else can claim a disproportionate burden but must document the assessment, renew it at least every five years and inform the market surveillance authorities. An EU declaration of conformity is drawn up by product manufacturers, while service providers describe conformity in publicly available information about the service. The European standard EN 301 549: the latest version the Commission calls harmonised is 3.2.1, based on WCAG 2.1; version 4.1.1 (September 2026) refers to WCAG 2.2 levels A and AA, and its legal weight depends on being cited in the Official Journal of the EU, so the status is checked on the day. Aiming at WCAG 2.2 AA is sensible because it covers the 2.1 requirements. For QA the consequence is practical: accessibility reports become evidence, not a formality.

Common mistakes.

  • "0 violations" as a verdict. A scanner does not judge the meaning of alt text or focus order, so missed defects reach users.
  • Checking only with a mouse. Then unreachable controls, invisible focus and traps in widgets stay unseen.
  • Contrast of text only. Field borders, icons and component states have their own 3:1 threshold (1.4.11).
  • One initial state. Dialogs, validation errors and menus are checked while open, because the scanner does not see what is hidden.
  • Custom elements instead of native ones. Every div button needs focus, keys and a role by hand, and that is exactly what is usually forgotten.

Check yourself

A sticky 80px header covers the "Next" button when it receives keyboard focus. Which criterion is violated and why is it only visible by hand?

Answer

2.4.11 Focus Not Obscured (Minimum), level AA: a focused element must not be entirely hidden by author content. The defect appears only during a Tab walk with scrolling in a real window, so a person reliably sees it, not a check of the markup in one state.

A close icon is 16 by 16 CSS pixels, and other buttons sit 2px away from it. Is that enough under 2.5.8?

Answer

No, unless an exception applies: the target is smaller than 24 by 24 CSS pixels, and a 24px circle around it reaches 4px beyond the icon and intersects neighbouring targets 2px away. An exception is given, for example, by another control that performs the same action and meets the requirement.

In the interview. Junior: I check accessibility against WCAG: with the keyboard and no mouse, with enlarged text, contrast, field labels and image alt text, plus an automated scanner. Middle/Senior: Automation in CI catches regressions but not meaning-related things, so I add a manual pass and a screen reader on key flows. I aim at WCAG 2.2 AA because it covers 2.1 and gives headroom for EU requirements, and I keep the reports as evidence of conformity.

More articles in this chapter