Writing Unit Tests
Use when writing or refactoring unit tests - a new test file, added cases, a flaky test, an unrea…
by riekelt
The skill
Use when writing or refactoring unit tests - a new test file, added cases, a flaky test, an unreadable one. Encodes behavior-first testing: one behavior per test, names that state the claim, deterministic setup, mocks only at boundaries you do not own. Use whenever a test is being written, even a quick one, and whenever a test needs a sleep, a mock of your own code, or a copy of the implementation's math.
This skill's licence does not allow redistribution, so the store does not show its text. Read it at the source.
Use this skill
Connect your agent to the Skill Store MCP server and ask for it by ref: riekelt/writing-unit-tests-1611388817.
Details
- Publisher
- riekelt
- Category
- Software Development › Testing & QA
- Updated
- 2026-09-11
References
More from riekelt
- Adding Dependencies Use when about to add, update, vet, or remove a dependency - a package, library, SDK, GitHub acti…
- Grounding Before Coding Use when starting any non-trivial change, investigating a bug, or working in unfamiliar code - be…
- Guarding Architecture Use when a change crosses module boundaries, adds a dependency direction between modules, touches…
- Handling Failures Use when writing or touching any error path, catch block, fallback, default value, retry, or degr…