Skip to content

Anki Playwright Agents Textbook

A free, self-paced textbook in 8 chapters. Read a chapter, then drill it with the 288 companion flashcards using spaced repetition.

8 chapters · 288 cards · Updated

Chapters

  1. 1Foundations: Installing and Configuring Playwright

    Playwright is a browser automation framework that drives Chromium, Firefox, and WebKit and ships with its own test runner, @playwright/test. To get a project running, install the t...

  2. 2Selectors, Locators, and Resilient Tests

    The single biggest source of flaky Playwright tests is bad selectors, so the framework steers you toward accessibility-driven queries. getByRole, getByLabel, getByPlaceholder, and...

  3. 3Assertions, Waits, and Avoiding Flakiness

    Playwright's auto-wait engine waits for elements to be attached, visible, stable, and enabled before acting, and it waits for navigation when appropriate. That means most tests don...

  4. 4Running, Tagging, and Debugging Tests

    Playwright's CLI exposes a rich set of run modes that help both humans and AI agents iterate quickly. npx playwright test runs everything; you can scope to one file (npx playwright...

  5. 5Authentication, State, and Data Isolation

    Logging in once and reusing the session across tests is one of the biggest speed and reliability wins in an E2E suite. The standard mechanism is storageState, a JSON file containin...

  6. 6Visual Regression and Snapshots

    Visual regression in Playwright comes from snapshot tests: expect(page).toHaveScreenshot('home.png') captures the page and compares it to a stored baseline, while expect(locator).t...

  7. 7CI/CD, Reports, and Parallel Execution

    A CI pipeline that runs Playwright reliably needs a few essentials. Install browsers with npx playwright install --with-deps so all required system libraries are present, export CI...

  8. 8Workspace Workflows and AI Agent Collaboration

    The local workspace contains two main product areas, each with a Vue 3 app, a Vue 2 app, and a Laravel backend. AMS lives under /root/myapp/admin with admin-2-vue (Vue 3), admin-vu...

← Back to the Anki Playwright Agents deck