Agent Skills
› codeaholicguy/ai-devkit
› dev-testing
dev-testing
GitHub指导AI开发测试阶段,涵盖编写单元测试与集成测试、运行覆盖率工具、识别并填补覆盖缺口。需遵循特定工作流规范,在变更前获取批准,并结合任务追踪记录证据,最终输出测试结果及后续建议。
Trigger Scenarios
用户希望编写新功能测试代码
需要更新测试文档或运行覆盖率检查
用户明确要求关闭测试覆盖缺口
执行开发生命周期第8阶段
Install
npx skills add codeaholicguy/ai-devkit --skill dev-testing -g -y
SKILL.md
Frontmatter
{
"name": "dev-testing",
"description": "AI DevKit · Testing phase guidance for adding and validating feature test coverage. Use when the user wants to write tests, update testing docs, run coverage, close coverage gaps, or run dev-lifecycle phase 8."
}
Dev Testing
Run testing work for configured AI docs features. Before changing docs or code, propose the concrete plan for this phase and wait for user approval unless the user already approved the exact phase plan.
Phase Contract
- Run
npx ai-devkit@latest lintbefore phase work. - If working on a named feature, run
npx ai-devkit@latest lint --feature <name>. - Read the testing doc, requirements, design, implementation notes, and current diff before changes.
- Apply the
verifyskill before making coverage or test-pass claims. - If parent
dev-lifecycleestablished usable task tracing, emit testing phase, next-action, and evidence events pertask.
Write Tests
Use for Phase 8.
- Run
npx ai-devkit@latest lint --feature <name>and reference the testing doc path it validates. If manual path resolution is unavoidable, first resolve.ai-devkit.jsonpaths.docs, falling back todocs/ai. - Gather context: feature name, changes summary, environment, existing test suites, flaky tests to avoid.
- Analyze the testing template, success criteria, edge cases, available mocks, and fixtures.
- Add unit tests for happy paths, edge cases, and error handling for each module. Highlight missing branches.
- Add integration tests for critical cross-component flows, setup/teardown, and boundary/failure cases.
- Run coverage tooling, identify gaps, and suggest additional tests if below the target.
- If task tracing is available, record evidence for each fresh test/coverage command per
task. - Update the selected testing doc with test file links and results.
Next: dev-review. If tests reveal design flaws, return to dev-design.
Version History
- d4caf56 Current 2026-07-05 15:22


