tdd-workflow
Plan, run, and report risk-based tests for software changes, using project-specific test and coverage requirements.
- License 许可
- MIT
- 最近更新
- 2026-11-15
- Stars
- ★ 1
- Forks
- 0
01 前言 Front Matter
- name
- tdd-workflow
- description
- Plan, run, and report risk-based tests for software changes, using project-specific test and coverage requirements.
02 资源文件 3
- 许可证LICENSE1.0 KB
- 参考文档provenance/original.SKILL.md9.6 KB
- 参考文档repair.json2.9 KB
03 SKILL.md 正文
Test-driven development workflow
Before repository work, read and apply Mandatory agent tools in the repository root at docs/agent-tools.md: Caveman for every task, CocoIndex Code before broad code navigation, and Crawl4AI for web-page research. Retain actual execution evidence.
Start with the requested behavior, the existing project instructions, and the affected contracts. Identify meaningful failures and choose unit, integration, or end-to-end tests appropriate to the change. Reproduce a bug or make a focused test fail before the repair when practical. Implement the smallest maintainable change, run the focused checks, and broaden them when project rules, risk, or observed failures require it. Avoid tests that merely restate an implementation or padding a metric.
Discover the actual commands and test runner from the project configuration. Use deterministic fixtures and clean up test-owned resources. Prefer observable behavior and important error paths over private implementation details. Mocks can isolate a unit, but validate integration boundaries with suitable real components when those boundaries matter.
For browser tests, set up controlled data, register any response wait before the action that triggers it, and use retrying assertions against observable results. Do not use a fixed sleep as a readiness signal. Use only routes, selectors, counts, clocks, and environment assumptions supplied by the application and its fixtures.
Coverage reports help locate unexercised code; they do not establish that assertions or behavior are correct. Honor the repository's existing coverage policy and report the measured scope, missing coverage, and genuinely unavailable checks. Do not invent a universal threshold or weaken an existing requirement. For a project that explicitly requires an 80% Jest threshold, its package.json configuration uses the singular option:
{
"jest": {
"coverageThreshold": {
"global": {
"branches": 80,
"functions": 80,
"lines": 80,
"statements": 80
}
}
}
}
Run Jest with coverage enabled when enforcing that configuration. Use the project's installed runner and version; verify its exit status and output. Report what passed, failed, was skipped, or was not run, and avoid claiming testing proves the absence of defects.
The original upstream skill is preserved at provenance/original.SKILL.md. This maintained overlay corrects selected testing guidance and a Jest configuration example; its component controls do not establish an improvement in agent performance.
04 同仓库更多 Skills
makefile-generator-project-wrappers
Repair Python, Java and generic GNU Make wrappers that report false success, miss changed inputs or clean dependency environments. Preserve the actual project build system and test runner; use when adapting the collection's original Makefile generator.
makefile-generator-go
Author or repair GNU Make wrappers for Go modules, retaining Go's dependency discovery and build cache. Use when wrapper timestamps hide embedded-resource changes or build failures; preserve the project's existing build system and real test commands.
strategic-compact-resume
Checkpoint and resume long agent work when context pressure or a handoff could lose constraints, verified progress, or ownership of active jobs.
makefile-generator-cpp
Author or repair GNU Make builds for C++ executables, preserving compiler/linker flags, header dependencies and real project test contracts. Use the optional scaffold for a flat src directory; retain an existing build system unless the task requires changing it.
eval-harness-integrity
Design and verify matched coding-agent evaluations when comparing skills, prompts, models, or harnesses using executable acceptance checks and native result evidence.
eval-harness-evidence
Design and verify matched coding-agent evaluations when comparing skills, prompts, models, or harnesses using executable acceptance checks and native result evidence.