Manuals / Cypress / Ch 11

E · Team CraftAdvanced60 min read

11. Team standards & flake governance

Cypress · 48 pages source format

Senior Cypress work is standards: folder layout, naming, PR checklist, selector policy, and flake ownership — so the suite survives beyond one author.

What you'll learn

  • Coding standard doc
  • PR template
  • Flake registry
  • Plugin tasks for seed data

Cypress standard one-pager

Folder layout, spec naming (*.cy.js), selector rules, no cy.wait(ms), intercept policy, session usage.

Do this now

Write CYPRESS-STANDARD.md. Apply to entire suite in one refactor PR.

Clear?

PR template

Checklist: new tests isolated, selectors stable, no sleeps, CI green, a11y if new page.

Do this now

Add .github/pull_request_template.md with Cypress checklist.

Clear?

Flake registry

FLAKES.md: date, spec name, root cause, fix, owner. Review monthly.

Do this now

Add at least one real or simulated flake entry with fix documentation.

Clear?

cy.task for DB seed (awareness)

Node tasks in setupNodeEvents can seed DB via API. Know the pattern for full-stack apps.

Do this now

Read Cypress task docs. Sketch how you would seed a user via API in setupNodeEvents.

Clear?

Checklist