Back to skills
SKILL.md
Atomic Tdd
ASecurity原子任务与红-绿-重构 TDD 铁律技能。强制先写失败测试、最小实现、真实背压验证与诚实证据报告。
- 2 stars
- 0 votes
- 0 copies
- 0 views
- Added December 2, 2026
Works with
Security analysis
100/100npx -y skills add yjfkpyu/AgentLock-Harness --skill atomic-tdd --agent claude-codeAre you the author of Atomic Tdd?
Add the live security badge to your README. It updates with every re-scan.
[](https://www.skillsdirectory.com/skills/yjfkpyu-atomic-tdd-agentlock-harness)---
name: atomic-tdd
description: 原子任务与红-绿-重构 TDD 铁律技能。强制先写失败测试、最小实现、真实背压验证与诚实证据报告。
---
# Atomic TDD — 原子迭代与确定性背压
## 执行步骤(完成后交棒 `cross-model-review`)
1. **单一原子目标**:一次只完成 1 个可独立验证的小目标,不顺手重构无关模块。
2. **Red(失败复现)**:先写失败测试复现问题或锁定契约,确认因行为未实现而失败(非语法错误)。
3. **Green(最小实现)**:写最小清晰实现,并确认公共入口/消费者真实接通。
4. **Refactor & Backpressure**:依次运行 `agentlock-harness.json` 中的 `lint` / `typecheck` / `test`,并用 `node scripts/doc-map.mjs . --changed <paths>` 检查受影响文档。
## 反偷懒 / 反理性化对照表
| 常见错误借口 | 强制反制动作 |
| :--- | :--- |
| “改动很小,肉眼看没问题,不用跑测试了” | 必须实际执行对应测试命令并附真实输出摘要,**禁止凭阅读宣称通过** |
| “先写完代码再补个测试一样” | 事后补测不得冒充先红后绿;核心逻辑/权限/回归缺陷必须先观测到失败测试 |
| “内部辅助函数测过了就算完成” | 必须验证公共导出/路由/CLI 消费者已接通,未接通必须明确报告剩余缺项 |
Attribution
Related skills
View all in ai-agents →Comments
Loading comments…
Newsletter
Get the weekly list of safe new skills, and the ones we pulled.