everything-claude-code-zh is a Chinese translation of a collection of configurations for Claude Code and other AI coding agents. It provides agents, skills, hooks, commands, rules, and MCP configurations intended to support development workflows such as memory persistence, security scanning, evaluation, and research-first work. The catalogue includes commands, skills, agents, instructions, and a plugin from this configuration set.
Borrowing it
Nothing to install: this file belongs to xu-xiang/everything-claude-code-zh. Take a copy, put it at the same path in your own repository, and replace the rules that are about this project with yours.
curl -O https://raw.githubusercontent.com/xu-xiang/everything-claude-code-zh/main/.agents/skills/tdd-workflow/SKILL.mdgit clone --depth 1 https://github.com/xu-xiang/everything-claude-code-zhWrote this? Show the measurements
A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.
[](https://agentmods.dev/skills/xu-xiang/everything-claude-code-zh/tdd-workflow)<a href="https://agentmods.dev/skills/xu-xiang/everything-claude-code-zh/tdd-workflow"><img src="https://agentmods.dev/badge/skills/xu-xiang/everything-claude-code-zh/tdd-workflow.svg" alt="Measured on agentmods" height="20"></a>- NVIDIA SkillSpector pass
What it costs to keep this loaded
Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.
| Model | Per session | Once invoked |
|---|---|---|
| Fable 5.1 | $0.00063 | $0.02827 |
| Opus 5 | $0.00032 | $0.01413 |
| Sonnet 5 | $0.00013 | $0.00565 |
| Haiku 4.5 | $0.00006 | $0.00283 |
Grade A, and why
tdd-workflow scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 8d ago.
A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.
Nothing flagged
None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.
How it starts
The opening of the file, as written. The whole thing — 411 lines — stays where its author put it; the contents beside it link to each section on GitHub.
测试驱动开发(TDD)工作流
此技能确保所有代码开发都遵循具有全面测试覆盖率的 TDD 原则。
何时激活
- 编写新功能或新逻辑
- 修复 Bug 或问题
- 重构现有代码
- 添加 API 端点
- 创建新组件
核心原则
1. 先测试,后代码(Tests BEFORE Code)
务必先编写测试,然后编写代码使测试通过。
2. 覆盖率要求
- 最低 80% 覆盖率(单元测试 + 集成测试 + E2E)
- 覆盖所有边缘情况(edge cases)
- 测试错误场景(error scenarios)
- 验证边界条件(boundary conditions)
3. 测试类型
单元测试(Unit Tests)
- 独立函数和工具方法
- 组件逻辑
- 纯函数
- 辅助函数和工具
集成测试(Integration Tests)
- API 端点
- 数据库操作
- 服务间交互
- 外部 API 调用
端到端测试(E2E Tests - Playwright)
- 关键用户流程
- 完整工作流
- 浏览器自动化
- UI 交互
TDD 工作流步骤
第 1 步:编写用户旅程(User Journeys)
作为 [角色],我想 [操作],以便 [收益]
示例:
作为一名用户,我想进行语义化的市场搜索,
以便即使没有精确的关键词也能找到相关的市场。
第 2 步:生成测试用例
为每个用户旅程创建全面的测试用例:
describe('语义化搜索', () => {
it('为查询返回相关的市场', async () => {
// 测试实现
})
it('优雅地处理空查询', async () => {
// 测试边缘情况
})
it('当 Redis 不可用时回退到子字符串搜索', async () => {
// 测试回退行为
})
it('按相似度得分对结果进行排序', async () => {
// 测试排序逻辑
})
})
第 3 步:运行测试(预期失败)
npm test
# 测试应该失败 - 我们还没有实现功能
第 4 步:实现代码
编写最少量的代码使测试通过:
// 由测试引导的实现
export async function searchMarkets(query: string) {
// 实现代码
}
第 5 步:再次运行测试
npm test
# 测试现在应该通过
第 6 步:重构(Refactor)
在保持测试通过的情况下提高代码质量:
- 消除重复
- 改进命名
- 优化性能
- 增强可读性
第 7 步:验证覆盖率
npm run test:coverage
# 验证是否达到了 80% 以上的覆盖率
测试模式(Patterns)
单元测试模式 (Jest/Vitest)
import { render, screen, fireEvent } from '@testing-library/react'
import { Button } from './Button'
describe('Button 组件', () => {
it('以正确的文本渲染', () => {
render(<Button>Click me</Button>)
expect(screen.getByText('Click me')).toBeInTheDocument()
})
it('点击时调用 onClick', () => {
const handleClick = jest.fn()
render(<Button onClick={handleClick}>Click</Button>)
fireEvent.click(screen.getByRole('button'))
expect(handleClick).toHaveBeenCalledTimes(1)
})
it('当 disabled 属性为 true 时被禁用', () => {
render(<Button disabled>Click</Button>)
expect(screen.getByRole('button')).toBeDisabled()
})
})
What ships with it
1 file beside SKILL.md in the same directory: the scripts, references and assets a skill reads on demand. Not counted in the per-session cost; read them before you install if any of them is executable.
What this file has done since we first saw it
Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.
- 8d ago First seen · 411 lines · 63 tokens per session scan A c36b7bfcd74a
tdd-workflow is a skill published in the GitHub repository xu-xiang/everything-claude-code-zh (1,933 stars, last pushed 6mo ago), licensed MIT. It adds 63 tokens to every session and 2,827 once invoked, about $0.0003 per session on Opus 5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-30.
Other skills, from other repositories
tdd-workflow
Use this skill when writing new features, fixing bugs, or refactoring code. Enforces test-driven development with 80%+ coverage including unit, integration, and E2E tests.
rust-testing
Rust testing patterns including unit tests, integration tests, async testing, property-based testing, mocking, and coverage. Follows TDD methodology.
cpp-testing
Use only when writing/updating/fixing C++ tests, configuring GoogleTest/CTest, diagnosing failing or flaky tests, or adding coverage/sanitizers.
systematic-debugging
4-phase root cause debugging: understand bugs before fixing.
test-driven-development
TDD: enforce RED-GREEN-REFACTOR, tests before code.
taiyi-dev
A software-development stage that implements planned tasks using test-driven development, or TDD: write a failing test, make it pass, then improve the code. It checks the task plan, dependencies, file boundaries, and required completion evidence.