backend-testing
Skill0 starsChanged 4 months agoMITView on GitHub
Turn backend test ambiguity into one practical test packet — API/service/repo/auth coverage, fixture & seed/reset strategy, mock-vs-container choices, contract checks, and flaky-suite stabilization across local and CI.
4 other projects use a version of this.
Adopted by
Most recently taken up by
- biersoeckli/QuickStacktheir own version, first seen Oct 8, 2026
- rhesis-ai/rhesistheir own version, first seen Oct 8, 2026
- pyaephyo11979/rent4Utheir own version, first seen Jun 24, 2026
- Typeless-Git/skillstheir own version, first seen Mar 30, 2026
Other versions4 projects use a version of this.
Word for word · 0
None found.
Edited · 0
None found.
Wrote their own version · 4
- rhesis-ai/rhesis★ 404same name
- biersoeckli/QuickStack★ 365same name
- pyaephyo11979/rent4U★ 4same name
- Typeless-Git/skills★ 1same name
How matches are found. Word for word: the exact same text. Edited: shares passages with this file (“99% same” means 99% of its five-word phrases also appear here; 10% or more counts). Their own version: similar meaning, or, weakest, the same name. We can’t tell which project had it first. Projects are counted among the 200 most-starred candidates, and mentions are links to the repository we found, up to 50 per site, so both counts are a floor.
In this repository63 other files it gives its agents.
- .claude/skills/nestjs-best-practices/AGENTS.mdAGENTS.md
- accessibility-a11ySkill
- architecture-blueprint-generatorSkill
- backend-delivery-loopSkill
- backend-designSkill
- backend-dev-guidelinesSkill
- backend-to-frontend-handoff-docsSkill
- building-componentsSkill
- bullmq-specialistSkill
- canvas-designSkill
- code-patternsSkill
- components-composition-patternsSkill
- conventional-commitSkill
- core-web-vitalsSkill
- create-svgSkill
- css-architectureSkill
- cypress-authorSkill
- cypress-docsSkill
- cypress-explainSkill
- delivery-loop-retroSkill
- diagnoseSkill
- fastify-best-practicesSkill
- figma-code-connectSkill
- frontend-delivery-loopSkill
- frontend-fundamentalsSkill
- fullstack-delivery-loopSkill
- grill-meSkill
- hunt-race-conditionSkill
- impeccableSkill
- mermaid-diagramsSkill
- nestjs-best-practicesSkill
- nextjs-best-practicesSkill
- nextjs-performanceSkill
- nodejs-backend-patternsSkill
- owasp-security-reviewSkill
- performance-hunterSkill
- playwright-best-practicesSkill
- postgresql-code-reviewSkill
- postgresql-optimizationSkill
- postmanSkill
- prisma-postgresSkill
- pro-state-machineSkill
- race-conditionSkill
- react-best-practicesSkill
- react-performanceSkill
- react-querySkill
- redis-coreSkill
- redis-query-engineSkill
- redis-securitySkill
- refactorSkill
- review-panelSkill
- run-delivery-chainSkill
- spec-drivenSkill
- sql-optimizationSkill
- system-designSkill
- testing-strategySkill
- tune-skills-and-agentsSkill
- ui-ux-pro-maxSkill
- vercel-react-view-transitionsSkill
- viteSkill
- The first 60 shown.
The file
Show its rules and text
We split this skill into the rules it gives an agent
14 rules. About 0 are common, 14 are distinctive, and 0 are very specific to this project.
≈0
Common · estimate
Many files like this have a rule of this kind.
≈14
Distinctive · estimate
This author's own choices. Worth a look.
0
Very specific
Tied to their project's names, files or tools. Probably skip.
- Common
- Distinctive
- Very specific
- Distinctive: line 22
If the request mixes several concerns, name the primary packet and one secondary concern.
- Distinctive: line 35
If the request is vague, choose the smallest regression slice worth protecting first.
- Distinctive: line 39
Use the packet and risk to select the lightest credible layer mix.
- Distinctive: line 43
Prefer when the main risk is branching logic, validation, orchestration, or pure-ish business rules.
- Distinctive: line 47
Prefer when database behavior, framework wiring, middleware, transactions, queues, caches, or serialization matter.
- Distinctive: line 51
Prefer when clients depend on response shapes, status codes, schemas, or events and the interface already exists.
- Distinctive: line 55
Prefer only when a narrow release-critical journey crosses several backend boundaries and lower layers would miss the core risk.
- Distinctive: line 70
prefer real DB behavior when repository, migration, transaction, or serialization behavior is central
- Distinctive: line 71
prefer mocks for outbound third-party APIs unless the integration contract itself is under test
- Distinctive: line 72
prefer a narrow containerized slice over a giant all-dependencies-in-PR setup
- Distinctive: line 73
do not claim fake and real dependencies are equivalent when production parity is the whole risk
- Distinctive: line 88
If the suite relies on ordering, leftovers, or sleeps, call that fragility out directly.
- Distinctive: line 92
Treat local, PR, and slower lanes as different jobs.
- Distinctive: line 101
If the suite is slow, split it.
≈ “Common” is an estimate: at least 1 in 5 of the 350,495 skill files we read have a rule of the same kind, not the same words. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.
Files
Backend Testing
Instructions
Step 1: Classify the request into one packet
Choose the single best entry packet before giving advice.
Packets
coverage-plan— which layers to add for a concrete backend changefixture-and-reset-plan— how to seed, isolate, reset, or bootstrap data/auth statecontract-and-api-checks— how to protect response/event/schema compatibility once the interface already existsflake-stabilization— how to stabilize CI-only or intermittent backend failuresexecution-lane-split— how to divide local-fast, PR, nightly, and release-only backend checks
If the request mixes several concerns, name the primary packet and one secondary concern.
Step 2: Frame the backend surface and risk
Capture the smallest useful context:
- surface: endpoint, service, repository, worker, queue consumer, auth flow, integration, or migration
- highest-risk behaviors: validation, permissions, persistence, retries, idempotency, ordering, serialization, side effects, compatibility
- existing coverage already present
- external dependencies involved: DB, cache, queue, email, payment, third-party API, identity provider, filesystem
- runtime/language stack
- where the evidence must hold: local loop, PR CI, scheduled CI, release smoke
If the request is vague, choose the smallest regression slice worth protecting first.
Step 3: Choose the right test layers
Use the packet and risk to select the lightest credible layer mix.
Unit / service
Prefer when the main risk is branching logic, validation, orchestration, or pure-ish business rules.
Integration
Prefer when database behavior, framework wiring, middleware, transactions, queues, caches, or serialization matter.
Contract / API
Prefer when clients depend on response shapes, status codes, schemas, or events and the interface already exists.
Smoke / selective end-to-end
Prefer only when a narrow release-critical journey crosses several backend boundaries and lower layers would miss the core risk.
State what is in scope, what is out of scope, and why.
Step 4: Decide dependency realism on purpose
For each dependency, choose one of:
- mock / stub — expensive, unstable, or irrelevant to the behavior under test
- fake / simulator — behavior matters, but a lightweight substitute is enough
- containerized real dependency — queries, migrations, message semantics, or wire behavior matter enough that drift would hurt
- shared external environment — only when unavoidable; call out the fragility cost explicitly
Good defaults:
- prefer real DB behavior when repository, migration, transaction, or serialization behavior is central
- prefer mocks for outbound third-party APIs unless the integration contract itself is under test
- prefer a narrow containerized slice over a giant all-dependencies-in-PR setup
- do not claim fake and real dependencies are equivalent when production parity is the whole risk
Step 5: Define fixture, data, auth, and environment control
A backend suite becomes untrustworthy when state is vague.
Specify:
- fixture/factory strategy
- seed/reset/rollback plan
- auth/bootstrap helpers for users, roles, tenants, tokens, or sessions
- time/randomness/idempotency control where needed
- isolation rule: per test, per file, per suite, or per environment
- debugging signals to capture when failures happen
If the suite relies on ordering, leftovers, or sleeps, call that fragility out directly.
Step 6: Split the execution lanes
Treat local, PR, and slower lanes as different jobs.
Define:
- local-fast path — what developers should run repeatedly
- PR path — what must gate merges
- scheduled / nightly path — heavier breadth or expensive realism
- release / incident path — narrow confidence checks or regression ratchets when needed
If the suite is slow, split it. Do not pretend one giant authoritative path is practical everywhere.
Step 7: Produce one backend test packet
Return one concise packet, not a general essay.
Recommended packet shapes:
coverage-plan→ coverage table + dependency strategy + exclusionsfixture-and-reset-plan→ fixture/reset memo + auth/bootstrap notescontract-and-api-checks→ compatibility packet + consumer/provider scope + route-outsflake-stabilization→ flake memo with likely causes, isolation fixes, readiness checks, and debug signalsexecution-lane-split→ lane matrix with local/PR/scheduled/release responsibilities
Minimum packet contents:
- change surface and primary risk
- chosen packet and any secondary concern
- selected layers and why
- dependency realism decisions
- fixture/data/auth/environment control
- execution-lane split
- explicit route-outs when the request is partly owned elsewhere
Step 8: Verify scope boundaries before finalizing
Check:
- does the packet protect the real backend regression risk rather than generic coverage vanity?
- did you keep org-wide validation policy in
testing-strategies? - did you route contract shape decisions to
api-designwhile keeping contract protection here only when the interface already exists? - did you route auth implementation work to
authentication-setup? - will a maintainer understand why a dependency is mocked, faked, containerized, or real?
Output format
## Backend Test Packet: [Surface or Change]
### Packet choice
- Primary packet: coverage-plan | fixture-and-reset-plan | contract-and-api-checks | flake-stabilization | execution-lane-split
- Secondary concern: optional
- Confidence: high | medium | low
### Change framing
- Surface: ...
- Main risks: ...
- Runtime: ...
- Existing coverage: ...
### Layer decisions
| Layer | In scope? | What it protects | Notes |
| --------------------- | --------- | ---------------- | ----- |
| Unit / service | yes/no | ... | ... |
| Integration | yes/no | ... | ... |
| Contract / API | yes/no | ... | ... |
| Smoke / selective E2E | yes/no | ... | ... |
### Dependency realism
| Dependency | Strategy | Why |
| ------------------------ | -------- | --- |
| Database / queue / cache | ... | ... |
| External API | ... | ... |
| Auth provider | ... | ... |
### Data and environment control
- Fixtures / factories: ...
- Seed / reset: ...
- Auth bootstrap: ...
- Isolation rule: ...
- Debug signals: ...
### Execution lanes
- Local-fast: ...
- PR CI: ...
- Scheduled / nightly: ...
- Release / incident: ...
### Route-outs
- `testing-strategies`: ...
- `api-design`: ...
- `authentication-setup`: ...Examples
Example 1: auth-heavy API change
Input: “We added refresh-token rotation and new admin-only endpoints to our Express API. I need backend tests that catch auth failures, token replay issues, and DB persistence bugs without turning CI into a giant end-to-end suite.”
Good response shape:
- chooses
coverage-planas the primary packet - combines unit/service plus integration/API coverage instead of one giant E2E suite
- keeps real DB or containerized persistence where token/session behavior matters
- defines auth bootstrap helpers and reset strategy
- limits smoke coverage to a narrow release-critical path
Example 2: CI-only flake in a service suite
Input: “Our FastAPI tests pass locally but fail in CI around seeded Postgres state and background jobs. Give me a stabilization plan.”
Good response shape:
- chooses
flake-stabilizationas the primary packet - identifies seed/reset drift, readiness, async timing, or leftover state as likely causes
- recommends stronger isolation, readiness checks, and debugging signals instead of just retries
- separates local-fast and CI-authoritative behavior clearly
Example 3: contract protection after an API already exists
Input: “Our payment service and webhook consumers keep drifting on response fields. I do not need API redesign, I need backend tests that catch compatibility regressions.”
Good response shape:
- chooses
contract-and-api-checksas the primary packet - keeps contract protection here because the interface already exists
- routes any schema redesign or versioning debate to
api-design - recommends consumer/provider or schema-compatibility coverage rather than broader smoke inflation
Example 4: too-broad policy request
Input: “Design our overall engineering org testing strategy for frontend, backend, mobile, and QA.”
Good response shape:
- recognizes that the primary task belongs to
testing-strategies - keeps any backend-specific advice scoped as a handoff only
- refuses to turn
backend-testinginto a universal QA-governance skill
Does it work?
Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.
No reviews yet
People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.
- It worked
- Partly
- It didn't
Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.
Your trail
Files you open will collect here, so you can find them again.
Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.
Now do this for your own.
Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.

