SKILL.md
qa-automation
Author end-to-end / UI-automation tests derived from the acceptance criteria, not from the implementation. Cover risk-tier critical journeys plus their key negative paths — not every path.
When to use / not use
- Use once acceptance criteria exist (from
/api-contract) and an env can be brought up. - Don't test against the implementation's internals, and never weaken assertions to
make a test pass.
Inputs
feature, acceptancecriteria, optional contractsummary (for cross-service journeys).
Steps
- Pick the framework from
skills.config.yaml→qa.framework(playwrightweb /
maestro mobile).
- Derive journeys from the acceptance criteria; rank by risk; pick the critical ones
and the highest-value negative paths. State what is out of scope.
- Design test data — each test seeds and tears down its own data; no shared mutable state.
- Author tests with stable selectors (roles/test-ids), explicit waits on conditions,
and assertions that verify observable behavior + the contract's outcomes.
- Run in a clean env —
stack up→ seed → ready_check → run →stack down(teardown
always runs).
- On failure, apply the fix-loop rule (selectors/flakes/waits only), bounded to 3.
Standards every suite must satisfy
- Risk-tiered — critical journeys + key negatives; explicit out-of-scope note.
- Isolated & idempotent — self-contained setup/teardown; order-independent.
- Deterministic — wait on conditions/selectors, never fixed sleeps; stable selectors,
not brittle CSS chains; control time/randomness where possible.
- Cross-service — real contract, not mocks, in the clean stack for cross-service journeys.
- No weakened assertions — self-healing may refresh selectors / re-run only; it must NOT
weaken assertions, permissions, or expected behavior (enforced by workflow.config.yaml → gates.freezeapprovedtests).
- Safe — no real secrets or production data; seeded test data only.
- Reportable — on failure, capture screenshot/trace/video and the failing step.
Edge cases / journeys to include
- Primary happy journey end-to-end across services.
- Validation failures surfaced to the user; permission-denied journey.
- Empty state and "many items" / pagination boundary.
- Slow/failed API handling (retry/error UI); session expiry mid-flow.
- Concurrency/double-submit where the journey allows it.
- Mobile: gestures, back button, deep links, orientation (Maestro).
External skill (provision — test generation)
Read skills.config.yaml → qa.external.generator (e.g. anthropics:webapp-testing, or none). If set, use it to generate tests — the output must still meet the standards above (isolation, determinism, real assertions, risk-tiering). If none, author in-pack.
Output
Write a coverage note to .sdlc/<slug>/qa/suite.md (journeys covered, negatives covered, out-of-scope, data strategy). Return suitepath and testspassed.
Definition of done
Critical journeys + key negatives automated and green in a clean env; tests isolated and deterministic; failures produce artifacts; nothing weakened to pass.