skills/e2e-testing-playwright/SKILL.md
To simulate real user scenarios from start to finish, ensuring that the integrated system (Frontend + Backend + Database) works as expected. Use when: Testing critical flows: Login, Checkout, Registration; Ensuring no regressions in core business logic.
npx skillsauth add jyjeanne/ai-setup-forge e2e-testing-playwrightInstall this skill globally with one command. Works with Claude Code, Cursor, and Windsurf.
3 of 9 scanners reported clean
Some scanners were skipped, did not run, or reported a non-clean status. Review each row below.
To simulate real user scenarios from start to finish, ensuring that the integrated system (Frontend + Backend + Database) works as expected.
Initialize Playwright in your project.
npm init playwright@latest
# Choose TypeScript, add GitHub Actions workflow, etc.
Create a spec file in the tests/ directory.
import { test, expect } from '@playwright/test';
test('user can login and see dashboard', async ({ page }) => {
// 1. Arrange
await page.goto('/login');
// 2. Act
await page.getByLabel('Email').fill('[email protected]');
await page.getByLabel('Password').fill('password123');
await page.getByRole('button', { name: 'Log in' }).click();
// 3. Assert
await expect(page).toHaveURL('/dashboard');
await expect(page.getByRole('heading', { name: 'Welcome back' })).toBeVisible();
});
Organize code into reusable Page Objects for better maintainability.
// models/LoginPage.ts
export class LoginPage {
constructor(private page: Page) {}
async goto() { await this.page.goto('/login'); }
async login(email, pass) {
await this.page.fill('#email', email);
await this.page.fill('#pass', pass);
await this.page.click('#submit');
}
}
Execute tests in different modes.
# Run all tests (headless)
npx playwright test
# Run with UI (best for debugging)
npx playwright test --ui
# Run specific file
npx playwright test login.spec.ts
test.beforeEach to reset state.getByRole, getByLabel, or data-testid instead of classes like .btn-primary.page.waitForTimeout(3000).A set of robust E2E tests that reliably verify critical user journeys across different browsers.
development
Generate breadboard circuit mockups and visual diagrams using HTML5 Canvas drawing techniques. Use when asked to create circuit layouts, visualize electronic component placements, draw breadboard diagrams, mockup 6502 builds, generate retro computer schematics, or design vintage electronics projects. Supports 555 timers, W65C02S microprocessors, 28C256 EEPROMs, W65C22 VIA chips, 7400-series logic gates, LEDs, resistors, capacitors, switches, buttons, crystals, and wires.
development
Apply lean thinking to UX: hypothesis-driven design, collaborative sketching, and rapid experiments instead of heavy deliverables. Use when the user mentions "Lean UX", "design hypothesis", "UX experiment", "collaborative design", or "outcome over output". Covers hypothesis statements, MVPs for UX, and cross-functional collaboration. For Build-Measure-Learn, see lean-startup. For usability audits, see ux-heuristics.
development
Design MVPs, validated learning experiments, and pivot-or-persevere decisions using Build-Measure-Learn. Use when the user mentions "MVP scope", "validated learning", "pivot or persevere", "vanity metrics", or "test assumptions". Covers innovation accounting and actionable metrics. For 5-day prototype testing, see design-sprint. For customer motivation analysis, see jobs-to-be-done.
tools
Instrument, trace, evaluate, and monitor LLM applications and AI agents with LangSmith. Use when setting up observability for LLM pipelines, running offline or online evaluations, managing prompts in the Prompt Hub, creating datasets for regression testing, or deploying agent servers. Triggers on: langsmith, langchain tracing, llm tracing, llm observability, llm evaluation, trace llm calls, @traceable, wrap_openai, langsmith evaluate, langsmith dataset, langsmith feedback, langsmith prompt hub, langsmith project, llm monitoring, llm debugging, llm quality, openevals, langsmith cli, langsmith experiment, annotate llm, llm judge.