Getting it into your agent
One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.
npx skills add xiaobei930/cc-best --skill testinggit clone --depth 1 https://github.com/xiaobei930/cc-bestWrote 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/xiaobei930/cc-best/testing)<a href="https://agentmods.dev/skills/xiaobei930/cc-best/testing"><img src="https://agentmods.dev/badge/skills/xiaobei930/cc-best/testing.svg" alt="Measured on agentmods" height="20"></a>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.00034 | $0.00943 |
| Opus 5 | $0.00017 | $0.00472 |
| Sonnet 5 | $0.00007 | $0.00189 |
| Haiku 4.5 | $0.00003 | $0.00094 |
Grade A, and why
testing 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 3d 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.
What it actually says
测试策略
关联 Agent:
tdd-guide(测试驱动开发)、code-reviewer(可测试性评估)、build-error-resolver(修复后测试验证)
本技能提供测试策略选择指南,整合 TDD(测试驱动开发)和 E2E(端到端测试)最佳实践。
子文件
- tdd.md - 测试驱动开发工作流
- e2e.md - Playwright E2E 测试指南
- tdd-example.md - 完整 TDD 会话示例
- frameworks.md - 测试框架配置与 Mock 模式
- qa-methodology.md - QA 角色方法论与验证流程
测试金字塔
┌─────────┐
│ E2E │ 少量:验证核心流程
├─────────┤
│集成测试 │ 中等:验证组件交互
├─────────┤
│单元测试 │ 大量:验证独立单元
└─────────┘
测试策略选择
| 场景 | 推荐策略 | 参阅文件 |
|---|---|---|
| 新功能开发 | TDD(测试先行) | tdd.md |
| Bug 修复 | 先写失败测试,再修复 | tdd.md |
| 核心用户流程验证 | E2E 测试 | e2e.md |
| 重构现有代码 | 先补测试,再重构 | tdd.md |
| UI 交互验证 | E2E + 视觉回归 | e2e.md |
覆盖率目标
| 代码类型 | 单元测试 | E2E 测试 |
|---|---|---|
| 核心业务逻辑 | 100% | 关键流程 |
| 普通业务代码 | 80%+ | 可选 |
| 工具函数 | 80%+ | 不需要 |
| UI 组件 | 70%+ | 关键交互 |
最佳实践
- 测试先行 - TDD 循环:RED → GREEN → REFACTOR
- 独立隔离 - 每个测试独立运行,无共享状态
- 快速反馈 - 单元测试 < 50ms,E2E 适度控制
- 语义命名 - 测试名称描述行为,不描述实现
- 分层覆盖 - 单元测试多,E2E 测试精
TDD 循环速览
RED → GREEN → REFACTOR → REPEAT
RED: 写一个失败的测试
GREEN: 写最少的代码使测试通过
REFACTOR: 改进代码,保持测试绿色
REPEAT: 下一个场景
详细指南参阅 tdd.md
E2E 测试速览
tests/
├── e2e/ # E2E 测试目录
│ ├── auth/ # 认证流程
│ └── core/ # 核心功能
├── pages/ # Page Object Model
└── playwright.config.ts
详细指南参阅 e2e.md
测试命令
# 单元测试
npm test
npm test -- --coverage
# E2E 测试
npx playwright test
npx playwright test --headed # 可视化
npx playwright test --debug # 调试模式
记住:测试不是可选项。它是支持自信重构、快速开发和生产可靠性的安全网。
What ships with it
5 files 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.
- 3d ago First seen · 102 lines · 34 tokens per session scan A dd80fe6adb34
testing is a skill published in the GitHub repository xiaobei930/cc-best (50 stars, last pushed 2mo ago), licensed MIT. It adds 34 tokens to every session and 943 once invoked, about $0.0002 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-09-03.
Other skills, from other repositories
moai-ref-testing-pyramid
Test pyramid strategy, coverage targets, test patterns, and quality metrics reference. Agent-extending skill that amplifies manager-develop test-creation and quality-validation work with production-grade testing patterns. NOT for: production code implementation, architecture design, DevOps, security audits.
memstack-development-test-writer
Use this skill when the user says 'write tests', 'add tests', 'test coverage', 'unit tests', 'integration tests', 'component tests', 'mocking', 'edge cases', or needs to generate tests with proper mocking and edge case coverage. Do NOT use for refactoring plans or database migrations.
plan-pipeline-execute
Execute a validated plan: worktree isolation, TDD scaffolding, level-based parallel agents, quality gate with smoke test, PR creation and merge. Handles everything through to merged PR.
qa
Systematic QA testing of a web application: diff-aware, tiered, with fix-and-verify loop.
plan-pipeline-eng-review
Engineering architecture gate: lock architecture, diagrams, edge cases, and test matrix before writing implementation code.
ci-all
Full CI pipeline: run local tests, type check, push branch, and return the pipeline URL. The only command you need before opening a PR.