e2e-testing-patterns

Provide end-to-end testing patterns for Playwright and Cypress.

38.6k|4.1k|Updated Jul 24, 2025
One-click install
npx skills add https://github.com/wshobson/agents --skill e2e-testing-patterns-wshobson
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: e2e-testing-patterns
Source: https://github.com/wshobson/agents/tree/main/plugins/developer-essentials/skills/e2e-testing-patterns
Command: npx skills add https://github.com/wshobson/agents --skill e2e-testing-patterns-wshobson

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill includes references (resource) components.

What problem does it solve?

This Skill helps developers build robust, maintainable, and fast end-to-end (E2E) test suites, reducing bugs and increasing deployment confidence.

Core Features & Use Cases

  • Framework Agnostic Patterns: Learn best practices applicable to both Playwright and Cypress.
  • Key Patterns: Master Page Object Model, custom commands, network mocking, visual regression, and accessibility testing.
  • Use Case: When implementing new E2E tests for a critical user flow like checkout, or when debugging flaky tests that are slowing down your CI pipeline.

Quick Start

Use the e2e-testing-patterns skill to generate a Playwright Page Object Model for a login page.

Frequently Asked Questions about e2e-testing-patterns

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I structure maintainable E2E tests using the Page Object Model?

The Page Object Model structures E2E tests by separating UI element selectors and interactions into reusable classes, reducing code duplication and making test suites easier to maintain when web application interfaces change.

What's the best way to debug flaky E2E tests in a CI pipeline?

Fix flaky E2E tests by implementing reliable wait strategies, network interception to mock unpredictable API responses, and custom commands to standardize test setup, ensuring consistent and fast automated test suite execution.

Can I use these E2E testing patterns with both Playwright and Cypress?

Yes, these E2E testing patterns provide framework-agnostic best practices applicable to both Playwright and Cypress, covering setup, custom commands, network mocking, visual regression, and accessibility testing.

How does network interception work in end-to-end web testing?

Network interception in E2E testing works by intercepting and mocking application network requests, allowing you to control API responses, simulate error states, and test frontend behavior without relying on live backend services.

When do I need visual regression testing in my automated test suite?

You need visual regression testing when verifying that UI changes do not unintentionally alter the visual appearance of web applications, capturing pixel differences to prevent unexpected visual defects during deployment.

Does this Skill support accessibility testing for web applications?

Yes, this Skill supports accessibility testing by providing patterns to integrate accessibility checks into your E2E test suites, ensuring web applications meet compliance standards alongside functional end-to-end validation.