
Cypress
This skill teaches you Cypress patterns that actually prevent flaky tests: data-testid selectors instead of brittle CSS, cy.intercept for network control, cy.session for fast auth, and deterministic waits instead of sleeps. It covers both E2E and component testing, with practical CI setup including retries and artifact management. The anti-patterns section is honest about what breaks in production (deep selectors, test order dependencies, mixing stubs with real backend calls). If you're debugging flaky UI tests or setting up browser automation for the first time, the troubleshooting guide alone is worth the tokens. Includes parallelization guidance for Cypress Cloud when test runtime becomes a bottleneck.
- skills.sh installs
- 664
- GitHub stars
- 79
- last updated
- Aug 21, 2026
Install
$ npx -y skills add bobmatnyc/claude-mpm-skills --skill cypress --agent claude-codeInstalls into .claude/skills of the current project.
Files
Cypress (E2E + Component Testing)
Overview
Cypress runs browser automation with first-class network control, time-travel debugging, and a strong local dev workflow. Use it for critical path E2E tests and for component tests when browser-level rendering matters.
Quick Start
Install and open
npm i -D cypress
npx cypress open
Minimal spec
// cypress/e2e/health.cy.ts
describe("health", () => {
it("loads", () => {
cy.visit("/");
cy.contains("Hello").should("be.visible");
});
});
Core Patterns
1) Stable selectors
Prefer data-testid (or data-cy) attributes for selectors. Avoid brittle CSS chains and text-only selectors for critical interactions.
<button data-testid="save-user">Save</button>
cy.get('[data-testid="save-user"]').click();
2) Deterministic waiting (avoid fixed sleeps)
Wait on app-visible conditions or network aliases rather than cy.wait(1000).
cy.intercept("GET", "/api/users/*").as("getUser");
cy.visit("/users/1");
cy.wait("@getUser");
cy.get('[data-testid="user-email"]').should("not.be.empty");
3) Network control with cy.intercept
Sponsors
Details
- Repository
- github.com/bobmatnyc/claude-mpm-skills
- Categories
- Frontend Development, Backend & APIs, Testing & QA
- First seen
- Jun 3, 2026
More from bobmatnyc/claude-mpm-skills
All 158- Session Compression664
- Opentelemetry647
- Hono Cloudflare639
- Wordpress Security Validation618
- Xlsx599
- Tanstack Query595
- Fastify582
- Api Design Patterns579
- Skill Creator569
- Git Workflow568
- Express Production519
- Golang Grpc518
- Axum500
- Hono Core500
- Zustand496
- Asyncio494
- Mcp Protocol Builder491
- Typescript Core487
- Bug Fix482
- Supabase Backend Platform482
- Mypy478
- Threat Modeling474
- Wordpress Block Editor Fse474
- Celery470