TDD
fossasia/eventyay-interpretation
Test-driven development. An agent skill from fossasia/eventyay-interpretation.
使用 RED-GREEN-重构(red-green-refactor)循环进行测试驱动开发。适用于用户希望用 TDD 构建新功能或修复 bug,提到 “red-green-refactor”,希望使用集成测试,或询问“test-first development(先写测试)”。
$ npx skills add ProgrammerAnthony/Anything-Extract --skill tdd -a claude-codeProject install by default; add -g for ~/.claude/skills/.
$ gh skill install ProgrammerAnthony/Anything-Extract tdd --agent claude-codeProject scope by default; add --scope user for a personal install. Needs GitHub CLI 2.90.0 or later (public preview).
$ git clone --depth 1 https://github.com/ProgrammerAnthony/Anything-Extract.git skills-src && mkdir -p .claude/skills && cp -r skills-src/.agents/skills/tdd .claude/skills/tdd && rm -rf skills-srcUse ~/.claude/skills/ instead of .claude/skills for a personal install. The folder must contain SKILL.md.
Claude Code skills documentation · loads skills from .claude/skills/
Install the "tdd" agent skill from https://github.com/ProgrammerAnthony/Anything-Extract/tree/master/.agents/skills/tdd into .claude/skills/tdd/ in this project. Copy the whole folder (SKILL.md and every file beside it), keep the folder name "tdd", then confirm the skill loads.Claude Code copies the folder itself, the same result as the manual copy. Check what it changed before you commit it.
$skill-installer install https://github.com/ProgrammerAnthony/Anything-Extract/tree/master/.agents/skills/tddType this inside Codex. $skill-installer <name> installs a curated skill from openai/skills. The installer writes to $CODEX_HOME/skills (default ~/.codex/skills). Restart Codex if the skill does not show up.
$ npx skills add ProgrammerAnthony/Anything-Extract --skill tdd -a codexProject install goes to .agents/skills/; add -g for ~/.codex/skills/.
$ gh skill install ProgrammerAnthony/Anything-Extract tdd --agent codexProject scope by default (.agents/skills/); add --scope user for a personal install.
$ git clone --depth 1 https://github.com/ProgrammerAnthony/Anything-Extract.git skills-src && mkdir -p .agents/skills && cp -r skills-src/.agents/skills/tdd .agents/skills/tdd && rm -rf skills-srcUse ~/.agents/skills/ instead of .agents/skills for a personal install.
Codex skills documentation · loads skills from .agents/skills/
Install the "tdd" agent skill from https://github.com/ProgrammerAnthony/Anything-Extract/tree/master/.agents/skills/tdd into .agents/skills/tdd/ in this project. Copy the whole folder (SKILL.md and every file beside it), keep the folder name "tdd", then confirm the skill loads.Codex copies the folder itself, the same result as the manual copy. Check what it changed before you commit it.
$ npx skills add ProgrammerAnthony/Anything-Extract --skill tdd -a cursorProject install goes to .agents/skills/; add -g for ~/.cursor/skills/.
$ gh skill install ProgrammerAnthony/Anything-Extract tdd --agent cursorProject scope by default (.agents/skills/); add --scope user for a personal install.
$ git clone --depth 1 https://github.com/ProgrammerAnthony/Anything-Extract.git skills-src && mkdir -p .cursor/skills && cp -r skills-src/.agents/skills/tdd .cursor/skills/tdd && rm -rf skills-srcUse ~/.cursor/skills/ instead of .cursor/skills for a personal install.
Cursor skills documentation · loads skills from .cursor/skills/, .agents/skills/, .claude/skills/, .codex/skills/
Install the "tdd" agent skill from https://github.com/ProgrammerAnthony/Anything-Extract/tree/master/.agents/skills/tdd into .cursor/skills/tdd/ in this project. Copy the whole folder (SKILL.md and every file beside it), keep the folder name "tdd", then confirm the skill loads.Cursor copies the folder itself, the same result as the manual copy. Check what it changed before you commit it.
$ gemini skills install https://github.com/ProgrammerAnthony/Anything-Extract.git --path .agents/skills/tdd--scope user (default) or --scope workspace; --path is the subfolder of the repo that holds the skill; --consent skips the security confirmation prompt.
$ npx skills add ProgrammerAnthony/Anything-Extract --skill tdd -a gemini-cliProject install goes to .agents/skills/; add -g for ~/.gemini/skills/.
$ gh skill install ProgrammerAnthony/Anything-Extract tdd --agent gemini-cliProject scope by default (.agents/skills/); add --scope user for a personal install.
$ git clone --depth 1 https://github.com/ProgrammerAnthony/Anything-Extract.git skills-src && mkdir -p .gemini/skills && cp -r skills-src/.agents/skills/tdd .gemini/skills/tdd && rm -rf skills-srcUse ~/.gemini/skills/ instead of .gemini/skills for a personal install, then run /skills reload.
Gemini CLI skills documentation · loads skills from .gemini/skills/, .agents/skills/
Install the "tdd" agent skill from https://github.com/ProgrammerAnthony/Anything-Extract/tree/master/.agents/skills/tdd into .gemini/skills/tdd/ in this project. Copy the whole folder (SKILL.md and every file beside it), keep the folder name "tdd", then confirm the skill loads.Gemini CLI copies the folder itself, the same result as the manual copy. Check what it changed before you commit it.
$ gh skill install ProgrammerAnthony/Anything-Extract tddInstalls for Copilot at project scope by default; add --scope user for a personal install. Preview a skill first with gh skill preview. Needs GitHub CLI 2.90.0 or later (public preview).
$ npx skills add ProgrammerAnthony/Anything-Extract --skill tdd -a github-copilotProject install goes to .agents/skills/; add -g for ~/.copilot/skills/.
$ git clone --depth 1 https://github.com/ProgrammerAnthony/Anything-Extract.git skills-src && mkdir -p .github/skills && cp -r skills-src/.agents/skills/tdd .github/skills/tdd && rm -rf skills-srcUse ~/.copilot/skills/ instead of .github/skills for a personal install. Commit .github/skills so cloud agent and code review can use it.
GitHub Copilot skills documentation · loads skills from .github/skills/, .claude/skills/, .agents/skills/
Install the "tdd" agent skill from https://github.com/ProgrammerAnthony/Anything-Extract/tree/master/.agents/skills/tdd into .github/skills/tdd/ in this project. Copy the whole folder (SKILL.md and every file beside it), keep the folder name "tdd", then confirm the skill loads.GitHub Copilot copies the folder itself, the same result as the manual copy. Check what it changed before you commit it.
$ npx skills add ProgrammerAnthony/Anything-Extract --skill tdd -a opencodeOpenCode documents no install command of its own. Project install goes to .agents/skills/; add -g for ~/.config/opencode/skills/.
$ gh skill install ProgrammerAnthony/Anything-Extract tdd --agent opencodeProject scope by default (.agents/skills/); add --scope user for a personal install.
$ git clone --depth 1 https://github.com/ProgrammerAnthony/Anything-Extract.git skills-src && mkdir -p .opencode/skills && cp -r skills-src/.agents/skills/tdd .opencode/skills/tdd && rm -rf skills-srcUse ~/.config/opencode/skills/ instead of .opencode/skills for a personal install.
OpenCode skills documentation · loads skills from .opencode/skills/, .claude/skills/, .agents/skills/
Install the "tdd" agent skill from https://github.com/ProgrammerAnthony/Anything-Extract/tree/master/.agents/skills/tdd into .opencode/skills/tdd/ in this project. Copy the whole folder (SKILL.md and every file beside it), keep the folder name "tdd", then confirm the skill loads.OpenCode copies the folder itself, the same result as the manual copy. Check what it changed before you commit it.
tdd使用 RED-GREEN-重构(red-green-refactor)循环进行测试驱动开发。适用于用户希望用 TDD 构建新功能或修复 bug,提到 “red-green-refactor”,希望使用集成测试,或询问“test-first development(先写测试)”。
TDD is an agent skill from ProgrammerAnthony/Anything-Extract. 使用 RED-GREEN-重构(red-green-refactor)循环进行测试驱动开发。适用于用户希望用 TDD 构建新功能或修复 bug,提到 “red-green-refactor”,希望使用集成测试,或询问“test-first development(先写测试)”。
Its SKILL.md is about 570 tokens, which your agent loads only when the skill is triggered. The skill folder holds 5 other files (for example `deep-modules.md`, `interface-design.md` and `mocking.md`).
It sits in Testing & QA, covering Test-driven development. The repository describes itself as: 高效文档识别&知识库&本地启动,前后端;整合QAnything、dify等思想和源码,快速批量可靠提取文档关键信息并导出. The licence is MIT.
4 steps, taken from the step headings in SKILL.md.
Read from SKILL.md and the folder at commit f1ed557. It shows what the files ask for, not the result of running them.
Pre-approves nothing: there is no allowed-tools line, so your agent's usual permission prompts apply.
From allowed-tools in the SKILL.md frontmatter.
No scripts in the folder and no shell commands in SKILL.md.
From the folder's file list and the shell code blocks in SKILL.md.
No URLs in SKILL.md.
From URLs in SKILL.md, links to its own repository left out.
Names no API keys, tokens, secrets or passwords.
From names ending in _API_KEY, _TOKEN, _SECRET, _KEY or _PASSWORD in SKILL.md.
TDD loads about 572 tokens when it runs. Until then it costs about 36 tokens; SKILL.md has 96 words of instructions outside code blocks.
Estimates: characters ÷ 4, the usual rule of thumb; real counts depend on the model's tokenizer. Scripts and assets cost tokens only if the agent reads them.
The automated check found no risky patterns in SKILL.md.
Automated static check — not a guarantee. Review scripts before installing. It scans the text of SKILL.md for risky patterns (piping downloads into a shell, reading credential files, hidden Unicode, destructive commands); files beside SKILL.md are not scanned.
The full file from ProgrammerAnthony/Anything-Extract at commit f1ed557, republished under its MIT licence (© ProgrammerAnthony). 96 words, ~572 tokens.
.claude/skills/tdd/SKILL.md (or your agent's skills folder). This skill also uses 5 other files; get the full folder from GitHub.核心原则:测试应当通过公共接口验证行为,而不是依赖实现细节。代码可以被完全重写;测试不应该随之频繁改变。
好的测试具有集成式特征:它会通过公共 API 实际跑通真实代码路径。它描述系统“做什么”,而不是“怎么做”。好的测试读起来像规范——例如“用户在使用有效购物车时可以结账”,你就能明确知道系统具备这个能力。由于测试不关心内部结构,它能在重构后继续存活。
坏的测试会耦合到实现。它们 mock 内部协作者、测试私有方法,或用“绕过接口”的方式验证(例如直接查询数据库而不是使用接口)。危险信号是:当你重构但行为没有变化时,测试却失败了;如果你重命名了某个内部函数导致测试失败,但用户可观察行为却没有变,这些测试是在测实现而不是在测行为。
查看 tests.md 获取更多示例,并查看 mocking.md 了解 mock 指南。
不要写“先写完所有测试,再写所有实现”。
这是一种“把 RED 当成写所有测试”的横向切片:把 RED 理解成“先写完所有测试”,把 GREEN 理解成“一次性写完所有代码”。
这会产生 烂测试(crap tests),包括:
正确做法:通过 tracer bullets 进行竖向切片(vertical slices)。一个测试 → 一个实现 → 重复。每一轮测试都会基于上一轮你从代码/理解中学到的东西来推进。由于你刚刚写完代码,所以你会非常清楚“哪些行为重要”以及“用什么方式验证它”。
WRONG(横向):
RED: test1, test2, test3, test4, test5
GREEN: impl1, impl2, impl3, impl4, impl5
RIGHT(竖向):
RED→GREEN: test1→impl1
RED→GREEN: test2→impl2
RED→GREEN: test3→impl3
...在写任何代码之前:
提问:公共接口应当长什么样?哪些行为最重要、最需要先测?
你无法把所有东西都测完。 请与用户明确“哪些行为最关键”。把测试资源集中在关键路径与复杂逻辑上,而不是覆盖所有可能的边界情况。
写出 一个测试,用来确认系统的 一个要点:
RED: 为第一个行为写测试 → 测试失败
GREEN: 写最小代码让测试通过 → 测试通过这就是你的 tracer bullet——它证明这条路径能端到端跑通。
对剩余的每个行为:
RED: 写下一个测试 → 失败
GREEN: 最小实现让它通过 → 通过规则:
当所有测试都通过之后,再查看 重构候选(refactoring.md):
不要在 RED 状态下重构。 先到 GREEN 再谈重构。
[ ] 测试描述的是行为,而不是实现
[ ] 测试只使用公共接口
[ ] 测试在内部重构后仍能存活
[ ] 针对该测试的代码足够最小
[ ] 没有加入“为了以后而猜”的功能© ProgrammerAnthony, MIT. Rendered from Markdown: HTML in the file is shown as text, images as links, and headings moved down two levels. Raw file
SKILL.md and 5 other files in .agents/skills/tdd of ProgrammerAnthony/Anything-Extract.
Open the folder on GitHubat commit f1ed557
TDD next to the 5 skills that share the most tags, products or categories with it. Stars are the repository's; “used in” counts other GitHub owners with a copy.
| Skill | Stars | Used in | Tokens | Auto-check | Licence | Repo updated |
|---|---|---|---|---|---|---|
| TDD this skillProgrammerAnthony/Anything-Extract | 139 | — | ~572 | Automated safety check: Pass | MIT | |
| TDDfossasia/eventyay-interpretation | 1.6k | 28 repos | ~1.1k | Automated safety check: Pass | Apache-2.0 | |
| TDD WorkflowhellangleZ/burn-in-cceverywhere-ralph | 112 | 11 repos | ~2.4k | Automated safety check: Pass | None | |
| TDDsanity-io/sanity | 6.4k | 20 repos | ~1k | Automated safety check: Pass | MIT | |
| Test Driven Developmentfarm-fe/farm | 5.6k | 49 repos | ~2.5k | Automated safety check: Pass | MIT | |
| Tapd Story PipelineTencentBlueKing/bk-bcs | 840 | — | ~2.6k | Automated safety check: Pass | Custom licence |
fossasia/eventyay-interpretation
Test-driven development. An agent skill from fossasia/eventyay-interpretation.
hellangleZ/burn-in-cceverywhere-ralph
A skill your agent uses when writing new features, fixing bugs, or refactoring code.
sanity-io/sanity
Test-driven development with red-green-refactor loop. An agent skill from sanity-io/sanity.
farm-fe/farm
A skill your agent uses when implementing any feature or bugfix, before writing implementation code
TencentBlueKing/bk-bcs
单需求实现流水线——把一个 TAPD 需求从零推进到代码提交。自动串联技术澄清、 开发计划、任务拆分、TDD 实现、架构/安全校验、代码提交六个阶段。
maddhruv/absolute
One-time setup for absolute: interview how you want it to behave (output style, autonomy, TDD strictness, spec dir, families) + detect the stack once, then write .absolute.config.json (project…
ProgrammerAnthony/Anything-Extract
指导在项目(python项目)中队后端代码进行质量、安全、可维护性与最佳实践审查,基于既定规则清单。适用于用户请求对 backend/ 下后端文件(如 .py)进行审查、分析或改进。不用于前端文件(如 .tsx、.ts、.js)。支持待提交变更审查、代码片段审查、按文件审查。
ProgrammerAnthony/Anything-Extract
指导在项目中对前端代码(Next.js/React/TypeScript/Tailwind 等)进行结构、可维护性、性能与一致性审查,基于既定规则清单。适用于用户请求审查 .tsx/.ts/.js/.jsx 等前端文件或前端目录下的页面与组件。不用于后端代码(如 .py)。
ProgrammerAnthony/Anything-Extract
使用并行子 agent 为某个模块生成多个根本不同的接口设计。适用于用户希望设计某个 API、探索接口选项、对比模块形状(module shapes),或提到“design it twice(把它设计两遍)”。
ProgrammerAnthony/Anything-Extract
从当前对话中抽取 DDD 风格的“统一语言”术语表(ubiquitous language glossary),标记歧义,并提出规范的术语选择。保存为 UBIQUITOUSLANGUAGE.md。适用于用户希望定义领域术语、构建术语表、固化用词并强化术语一致性,或提到 “domain model” / “DDD”(领域模型与 DDD)。
ProgrammerAnthony/Anything-Extract
以正确的技能结构、渐进式披露与打包资源来创建新的 agent 技能。适用于用户希望创建、编写或构建新的技能. An agent skill from ProgrammerAnthony/Anything-Extract.
ProgrammerAnthony/Anything-Extract
指导在项目中编写、更新与使用架构文档(ARCHITECTURE.md)。在根目录维护架构文档,修改前后需阅读文档;文档关注最终结果与流程串联,不陷入实现细节。适用于新增/变更功能、重构、或需要理解系统整体时。
Categories
使用 RED-GREEN-重构(red-green-refactor)循环进行测试驱动开发。适用于用户希望用 TDD 构建新功能或修复 bug,提到 “red-green-refactor”,希望使用集成测试,或询问“test-first development(先写测试)”。. TDD is an agent skill from ProgrammerAnthony/Anything-Extract.
TDD fits situations like: tasks that involve Test-driven development.
Run `npx skills add ProgrammerAnthony/Anything-Extract --skill tdd -a claude-code`. Or copy the skill folder (.agents/skills/tdd in ProgrammerAnthony/Anything-Extract) into .claude/skills/tdd in your project. Claude Code loads it when a task matches its description.
Run `npx skills add ProgrammerAnthony/Anything-Extract --skill tdd -a codex`. Or copy the skill folder (.agents/skills/tdd in ProgrammerAnthony/Anything-Extract) into .agents/skills/tdd in your project. Codex loads it when a task matches its description.
Cursor, Gemini CLI, GitHub Copilot and OpenCode also load SKILL.md folders. With the skills CLI, run `npx skills add ProgrammerAnthony/Anything-Extract --skill tdd -a cursor` (or -a gemini-cli, github-copilot or opencode for the others). To copy it by hand, put the folder in .cursor/skills/tdd, .gemini/skills/tdd, .github/skills/tdd and .opencode/skills/tdd in your project.
SKILL.md names no scripts, command-line tools or credentials: TDD is instructions for the agent only.
SKILL.md contains no URLs. Any network use would come from the scripts or tools the agent runs. This is read from the text; nothing was executed.
Our automated static check of SKILL.md found no risky patterns, such as piping downloads into a shell, reading credential files or hidden Unicode. It is not a guarantee. Review the folder before installing.
TDD is published under the MIT licence (the repository's licence). It allows redistribution, so the full SKILL.md is shown on this page.
About 572 tokens (SKILL.md is roughly 2.3k characters). Agents keep only the skill's name and description in context until a task matches; then they load SKILL.md in full.
Skills that share tags, products or a category with TDD: TDD (fossasia/eventyay-interpretation, 1.6k stars), TDD Workflow (hellangleZ/burn-in-cceverywhere-ralph, 112 stars), TDD (sanity-io/sanity, 6.4k stars) and Test Driven Development (farm-fe/farm, 5.6k stars). The comparison table on this page puts their stars, adoption, token cost, safety result and licence side by side.
ProgrammerAnthony (a GitHub user) maintains it in ProgrammerAnthony/Anything-Extract, which has 139 GitHub stars. The repository holds 13 skills in this directory. The repository was last updated on May 13, 2026.
Source: ProgrammerAnthony/Anything-Extract on GitHub. Facts on this page come from the repository at the commit we read; the author's words are quoted as theirs.