Reference · Living Document
Glossary: Claude Code E2E / UI Testing
The shared vocabulary for this mission. Terms here are used consistently across every lesson.
- E2E (End-to-End) test
- A test that exercises your app the way a real user would — through the actual UI in a real browser — start to finish (e.g. "log in, add an item to the cart, check out"). Contrast with a unit test, which checks one function in isolation.
- UI test
- Loosely interchangeable with E2E here. Any test that interacts with the rendered interface (clicking, typing, reading text) rather than calling code directly.
- Playwright tool
- An open-source browser-automation library (by Microsoft) that can drive Chromium, Firefox, and WebKit. It's the engine that actually clicks and types in the browser. It powers both hand-written test scripts and the MCP server below.
- MCP (Model Context Protocol) infra
- An open standard (from Anthropic) that lets an AI model call external tools. An "MCP server" hands Claude a menu of actions it can take in the real world.
- Playwright MCP key
- The
@playwright/mcpserver. It exposes Playwright's browser actions as MCP tools, so Claude can live-drive a browser: navigate, click, fill, snapshot, screenshot, inspect network. This is the primary way Claude autonomously tests a web app. - Accessibility snapshot (a11y tree)
- A structured, text description of every interactive element on the page (buttons, inputs, links) with stable references. Playwright MCP gives Claude this instead of raw pixels — so Claude acts on real elements deterministically rather than guessing from a screenshot.
- Selector / locator
- How you point at an element on a page — e.g. by role (
button "Submit"), by text, or by adata-testidattribute. Good selectors are stable; brittle ones (like deep CSS paths) break when the page changes. - Assertion
- The check that decides pass or fail — e.g. "expect the page to show Welcome, Alex". A test without an assertion only proves it didn't crash, not that anything worked.
- The agentic loop
- Claude's core testing rhythm: read page state → act (click/type) → observe the result → decide the next step. It's a live conversation with the page, not a pre-written script run blindly.
- Headless / headed
- Headed = browser window is visible (good while learning). Headless = no visible window (required for CI servers with no display).
- Flaky test
- A test that passes sometimes and fails other times without the code changing — usually a timing issue (acting before the page is ready). The #1 frustration in E2E.
- Claude in Chrome alt
- A Claude extension that drives your own logged-in Chrome. Handy for one-off checks against authenticated state, but less repeatable / CI-friendly than Playwright MCP.
- CI (Continuous Integration)
- An automated server (e.g. GitHub Actions) that re-runs your tests on every code change. The destination once your manual checks become committed Playwright tests.