·tdd

使用红绿重构循环的测试驱动开发。当用户想要使用 TDD 构建功能或修复错误、提到“红绿重构”、想要集成测试或要求测试优先开发时使用。

51安装·3热度·@brianlovin

安装

$npx skills add https://github.com/brianlovin/claude-config --skill tdd

如何安装 tdd

通过命令行快速安装 tdd AI 技能到你的开发环境

  1. 打开终端: 打开你的终端或命令行工具(如 Terminal、iTerm、Windows Terminal 等)
  2. 运行安装命令: 复制并运行以下命令:npx skills add https://github.com/brianlovin/claude-config --skill tdd
  3. 验证安装: 安装完成后,技能将自动配置到你的 AI 编程环境中,可以在 Claude Code、Cursor 或 OpenClaw 中使用

来源:brianlovin/claude-config。

SKILL.md

查看原文

Core principle: Tests should verify behavior through public interfaces, not implementation details. Code can change entirely; tests shouldn't.

Good tests are integration-style: they exercise real code paths through public APIs. They describe what the system does, not how it does it. A good test reads like a specification - "user can checkout with valid cart" tells you exactly what capability exists. These tests survive refactors because they don't care about internal structure.

Bad tests are coupled to implementation. They mock internal collaborators, test private methods, or verify through external means (like querying a database directly instead of using the interface). The warning sign: your test breaks when you refactor, but behavior hasn't changed. If you rename an internal function and tests fail, those tests were testing implementation, not behavior.

可引用信息

为搜索与 AI 引用准备的稳定字段与命令。

安装命令
npx skills add https://github.com/brianlovin/claude-config --skill tdd
分类
</>开发工具
认证
收录时间
2026-02-22
更新时间
2026-03-10

Browse more skills from brianlovin/claude-config

快速解答

什么是 tdd?

使用红绿重构循环的测试驱动开发。当用户想要使用 TDD 构建功能或修复错误、提到“红绿重构”、想要集成测试或要求测试优先开发时使用。 来源:brianlovin/claude-config。

如何安装 tdd?

打开你的终端或命令行工具(如 Terminal、iTerm、Windows Terminal 等) 复制并运行以下命令:npx skills add https://github.com/brianlovin/claude-config --skill tdd 安装完成后,技能将自动配置到你的 AI 编程环境中,可以在 Claude Code、Cursor 或 OpenClaw 中使用

这个 Skill 的源码在哪?

https://github.com/brianlovin/claude-config

详情

分类
</>开发工具
来源
skills.sh
收录时间
2026-02-22