Skip to content

Latest commit

 

History

History
54 lines (38 loc) · 3.12 KB

File metadata and controls

54 lines (38 loc) · 3.12 KB

testing — Domain Index

Route here for: writing or structuring automated tests — choosing the test level, selecting cases and assertions, test data and isolation, mock/fake decisions, fixing flaky tests, verifying tests can actually fail, testing async code (promises/timers/events), and browser E2E selector/wait/setup strategy. Release-process quality (gates, manual testing, bug triage) → wiki/qa/.

Match your situation to a "load when" line; load only matching pages.

strategy

Page Load when
test-level-choice Deciding at which level (unit/integration/e2e) to test new or changed behavior; reviewing a test plan's level distribution; logic buried in a controller or framework wiring needs coverage

quality

Page Load when
minimum-case-set Writing tests for a function/endpoint/change and choosing which cases to cover; reviewing whether coverage suffices; picking boundary values by input type; adding a regression test for a bug fix
behavior-not-implementation Deciding what a test should assert; a behavior-preserving refactor broke tests; tempted to expose privates for testing; deciding whether a snapshot test is appropriate
tests-that-cannot-fail Reviewing tests that always pass; a bug shipped through an area the suite reported as covered; auditing a suspiciously green suite; judging whether an assertion, error-path test, or mock-based test can actually detect a defect

data

Page Load when
test-data-and-isolation Tests need fixture data and you are choosing how to create it; tests pass alone but fail together (or vice versa); DB cleanup, shared fixtures, time-dependent logic, or unique-value collisions

mocking

Page Load when
what-to-mock Deciding whether to mock/stub/fake a dependency or use the real one; mocks breaking on refactors; testing handling of a third-party's failure modes; the same mock setup is copy-pasted across tests

flaky

Page Load when
diagnosing-flaky-tests A test fails intermittently with no code change: on retry, in CI only, or only when run with other tests; deciding policy for a newly identified flaky test (quarantine vs retry)

async

Page Load when
async-testing Testing async code — promises, timers, retries, debounce, event-driven flows; the runner warns about assertions after completion or un-awaited promises; an async test intermittently interferes with the next test; deciding between fake timers and condition waits

e2e

Page Load when
e2e-stability Writing browser E2E tests (Playwright/Cypress-style); an E2E suite is flaky or slow; choosing selectors (role/label vs test id vs CSS), wait strategy, auth/data setup layer, or what to stub at the network edge