tdd — community relay-api, community, ide skills

v1.0.0

关于此技能

非常适合需要强大的API测试和验证能力的测试驱动开发代理。 Test-driven development — write failing test first, then implement (red-green-refactor)

g-zenr g-zenr
[0]
[0]
更新于: 2/13/2026

Killer-Skills Review

Decision support comes first. Repository text comes second.

Reference-Only Page Review Score: 6/11

This page remains useful for operators, but Killer-Skills treats it as reference material instead of a primary organic landing page.

Original recommendation layer Concrete use-case guidance Explicit limitations and caution
Review Score
6/11
Quality Score
35
Canonical Locale
en
Detected Body Locale
en

非常适合需要强大的API测试和验证能力的测试驱动开发代理。 Test-driven development — write failing test first, then implement (red-green-refactor)

核心价值

赋予代理在实现之前使用红绿重构周期编写失败的测试的能力,确保使用FastAPI和HID控制的USB继电器模块的线程安全访问和故障安全设计,同时利用REST API进行全面内容分析。

适用 Agent 类型

非常适合需要强大的API测试和验证能力的测试驱动开发代理。

赋予的主要能力 · tdd

为有效输入场景编写成功路径测试
为无效输入处理生成验证错误测试
调试外部依赖项中的服务和设备错误

! 使用限制与门槛

  • 需要严格遵守红绿重构周期
  • 仅限HID控制的USB继电器模块
  • 依赖FastAPI进行REST API实现

Why this page is reference-only

  • - Current locale does not satisfy the locale-governance contract.
  • - The underlying skill quality score is below the review floor.

Source Boundary

The section below is imported from the upstream repository and should be treated as secondary evidence. Use the Killer-Skills review above as the primary layer for fit, risk, and installation decisions.

评审后的下一步

先决定动作,再继续看上游仓库材料

Killer-Skills 的主价值不应该停在“帮你打开仓库说明”,而是先帮你判断这项技能是否值得安装、是否应该回到可信集合复核,以及是否已经进入工作流落地阶段。

实验室 Demo

Browser Sandbox Environment

⚡️ Ready to unleash?

Experience this Agent in a zero-setup browser environment powered by WebContainers. No installation required.

Boot Container Sandbox

常见问题与安装步骤

以下问题与步骤与页面结构化数据保持一致,便于搜索引擎理解页面内容。

? FAQ

tdd 是什么?

非常适合需要强大的API测试和验证能力的测试驱动开发代理。 Test-driven development — write failing test first, then implement (red-green-refactor)

如何安装 tdd?

运行命令:npx killer-skills add g-zenr/relay-api。支持 Cursor、Windsurf、VS Code、Claude Code 等 19+ IDE/Agent。

tdd 适用于哪些场景?

典型场景包括:为有效输入场景编写成功路径测试、为无效输入处理生成验证错误测试、调试外部依赖项中的服务和设备错误。

tdd 支持哪些 IDE 或 Agent?

该技能兼容 Cursor, Windsurf, VS Code, Trae, Claude Code, OpenClaw, Aider, Codex, OpenCode, Goose, Cline, Roo Code, Kiro, Augment Code, Continue, GitHub Copilot, Sourcegraph Cody, and Amazon Q Developer。可使用 Killer-Skills CLI 一条命令通用安装。

tdd 有哪些限制?

需要严格遵守红绿重构周期;仅限HID控制的USB继电器模块;依赖FastAPI进行REST API实现。

安装步骤

  1. 1. 打开终端

    在你的项目目录中打开终端或命令行。

  2. 2. 执行安装命令

    运行:npx killer-skills add g-zenr/relay-api。CLI 会自动识别 IDE 或 AI Agent 并完成配置。

  3. 3. 开始使用技能

    tdd 已启用,可立即在当前项目中调用。

! 参考页模式

此页面仍可作为安装与查阅参考,但 Killer-Skills 不再把它视为主要可索引落地页。请优先阅读上方评审结论,再决定是否继续查看上游仓库说明。

Upstream Repository Material

The section below is imported from the upstream repository and should be treated as secondary evidence. Use the Killer-Skills review above as the primary layer for fit, risk, and installation decisions.

Upstream Source

tdd

安装 tdd,这是一款面向AI agent workflows and automation的 AI Agent Skill。查看评审结论、使用场景与安装路径。

SKILL.md
Readonly
Upstream Repository Material
The section below is imported from the upstream repository and should be treated as secondary evidence. Use the Killer-Skills review above as the primary layer for fit, risk, and installation decisions.
Supporting Evidence

Implement using TDD: $ARGUMENTS

Follow the red-green-refactor cycle strictly.

Phase 1 — RED: Write Failing Tests

  1. Understand the requirement: What should the feature/fix do?
  2. Choose test file: Use the test file mapping in project config
  3. Write tests BEFORE any implementation code:
    • Success path test — what should happen with valid input
    • Validation error test — what should happen with invalid input
    • Service/device error test — what should happen when external resource is unavailable
  4. Run tests — they MUST fail. If tests pass without implementation, they're testing nothing.

Test Conventions

  • Class: Test<Feature>
  • Method: test_<action>_<expected_outcome>
  • Fixtures with proper type hints and cleanup
  • Test HTTP client configured for proper error testing (no automatic error propagation)
  • Audit log tests with log capture mechanism (see stack concepts) on the project's audit logger

Phase 2 — GREEN: Minimal Implementation

  1. Write the minimum code to make tests pass — nothing more
  2. Follow project standards:
    • Future annotations pattern (see stack concepts)
    • Typed exceptions from the exception hierarchy
    • Thread safety in service layer
    • Typed schemas for API shapes (see stack concepts)
    • Thin route handlers with DI injection (see stack concepts)
  3. Run tests — they MUST now pass

Phase 3 — REFACTOR: Clean Up

  1. Remove duplication
  2. Improve naming
  3. Extract helpers if three or more similar patterns exist
  4. Ensure layer boundaries are respected
  5. Run full suite — nothing must break. Run test and type-check commands (see project config).

Phase 4 — Complete

  1. Verify audit logging if state changes were added
  2. Update OpenAPI metadata (summary, description, responses)
  3. Update project documentation if new endpoints or config were added
  4. Run final verification with the test and type-check commands

相关技能

寻找 tdd 的替代方案 (Alternative) 或可搭配使用的同类 community Skill?探索以下相关开源技能。

查看全部

openclaw-release-maintainer

Logo of openclaw
openclaw

Your own personal AI assistant. Any OS. Any Platform. The lobster way. 🦞

333.8k
0
AI

widget-generator

Logo of f
f

为prompts.chat的信息反馈系统生成可定制的插件小部件

149.6k
0
AI

flags

Logo of vercel
vercel

React 框架

138.4k
0
浏览器

pr-review

Logo of pytorch
pytorch

Python中具有强大GPU加速的张量和动态神经网络

98.6k
0
开发者工具