self-test

self-test is a skill for Claude Code from Today-Hbw/claude-code-dev-workflow. It costs 26 tokens per session (1,170 once invoked), scanned A, original, MIT.

A post-coding self-check checklist for reviewing implementation quality and tests. It checks user-visible behavior, data consistency, dependencies, compatibility, code quality, and—when relevant—visual details against a design.

In plain words
What is it for?
Use it after coding to review feature coverage, error handling, database changes, external dependencies, backward compatibility, test quality, and UI details.
Why use it?
It helps catch missing requirements, edge cases, broken data flows, leftover debugging work, and tests that depend too heavily on internal code structure.

Skill for Claude Code

Written for Claude Code: shipped in a Claude Code plugin.

Part of the dev-flow plugin — 4 skills, 1 command shipped together

Good fit Use it after coding to review feature coverage, error handling, database changes, external dependencies, backward compatibility, test quality, and UI details.

Compare 6 skills from other repositories ↓
Install with agentmods
npx agentmods add skills/today-hbw/claude-code-dev-workflow/self-test
Install

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.

Any agent
npx skills add Today-Hbw/claude-code-dev-workflow --skill self-test
Clone the repo
git clone --depth 1 https://github.com/Today-Hbw/claude-code-dev-workflow

Made for: Claude Code.

Or install dev-flow, the plugin that ships this one along with the rest of its 4 skills, 1 command.

Wrote 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.

agentmods badge for self-test

README.md
[![agentmods](https://agentmods.dev/badge/skills/today-hbw/claude-code-dev-workflow/self-test/github.svg)](https://agentmods.dev/skills/today-hbw/claude-code-dev-workflow/self-test)
Your own site
<a href="https://agentmods.dev/skills/today-hbw/claude-code-dev-workflow/self-test"><img src="https://agentmods.dev/badge/skills/today-hbw/claude-code-dev-workflow/self-test/github.svg" alt="Measured on agentmods" height="20"></a>

Or the 80×15 button, for a site that already has a row of RSS and ATOM ones. Only the verdict fits; the numbers stay here.

agentmods 80×15 button for self-test

Your own site · 80×15
<a href="https://agentmods.dev/skills/today-hbw/claude-code-dev-workflow/self-test"><img src="https://agentmods.dev/badge/skills/today-hbw/claude-code-dev-workflow/self-test.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 26 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 1,170 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. A grade says what 26 rules found in the file — not that it is safe. Third-party audits
  • NVIDIA SkillSpector pass 7 Sept 2026
How audits are shown
Origin original No closer match found in the catalogue.
Token cost

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.

ModelPer sessionOnce invoked
Fable 5.1 $0.00026 $0.01170
Opus 5.5 $0.00010 $0.00468
Sonnet 5.5 $0.00005 $0.00234
Haiku 4.5 $0.00003 $0.00117

Measured 1mo ago against content hash 496b043ba38d, method: parsed. Prices are Anthropic first-party input rates as of 2026-10-07, from the pricing page.

Security

Grade A, and why

self-test 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 1mo 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.

plugins/dev-flow/skills/self-test/SKILL.md · 117 lines

What it actually says

自测 · 检查清单

你的任务

编码完成后,按照以下清单逐项检查,确保代码质量。

测试哲学

在检查之前,先确认测试本身的质量:

好测试的特征:

  • 通过公共接口验证行为,不关心内部实现
  • 读起来像规格说明:"用户可以带着有效购物车结算"
  • 内部重构后依然通过(测试的是"做什么",不是"怎么做")

坏测试的特征:

  • mock 内部协作者、测试私有方法
  • 改了内部函数名就挂,但行为没变
  • 描述的是实现细节而非用户可见行为

警告信号:如果你的测试在重构后失败,但行为没变,说明测试在测实现而非行为。

检查清单

1. 功能验证

  • 每个任务的核心功能是否实现(对照计划.md 的验收标准逐条检查)
  • 是否覆盖了 QA 中提到的所有场景
  • 边界条件是否处理(空值、极值、异常输入)
  • 错误提示是否友好(用户能看到有意义的错误信息)

2. 数据一致性

  • 数据库字段是否与 Schema 描述一致
  • 新增/修改/删除操作是否完整
  • 数据流转是否正确(从输入到存储到展示)

3. 依赖检查

  • 外部依赖(接口、表、配置)是否就绪
  • 依赖的字段/列是否存在
  • 同步任务/ETL 是否需要配合

4. 代码质量

  • 是否有遗留的 TODO 或调试代码
  • 命名是否清晰(变量、函数、文件)
  • 注释是否充分(复杂逻辑处)
  • 是否有重复代码可以提取

5. 兼容性

  • 是否与现有功能兼容(不破坏已有逻辑)
  • 接口变更是否有向后兼容处理

6. 测试质量

  • 测试是否通过公共接口验证行为
  • 测试是否能扛住内部重构(重命名内部函数不应让测试挂掉)
  • 是否避免了横向切片(不要先批量写所有测试,再批量写所有实现)
  • 测试命名是否描述了行为而非实现("用户可以结算"而非"调用了 processOrder 函数")

7. 视觉规格核对(对照 PRD 截图/原型)

仅当本次涉及 UI 时执行。基准是 PRD 原图,不因 计划.md 未写而跳过——上游可能漏抽截图规格。

  • 字段列归属:新增字段折进已有列还是独立列,与截图一致
  • 字段/筛选顺序:同一列或区域内排列顺序与截图一致
  • 按钮/入口文案:与截图逐字一致,未自拟或改写
  • 所在容器:按钮/筛选挂在截图指定的页签/工具栏,未擅自新建页签或区域
  • 筛选项位置:与截图中现有筛选的并列关系一致
  • 若实现与截图不符:修正实现,不改截图规格

反模式警示

横向切片(要避免)

❌ 错误方式:
  RED:   test1, test2, test3, test4, test5   ← 批量写测试
  GREEN: impl1, impl2, impl3, impl4, impl5   ← 批量写实现

正确方式(垂直切片):
  test1→impl1  →  test2→impl2  →  test3→impl3  → ...

批量写的测试测的是想象中的行为,而不是实际实现的行为。每个测试应该是对前一轮实现的响应。

输出格式

## 自测结果

### ✅ 通过项
- <通过的检查项>

### ⚠️ 需注意
- <需要关注但不是阻塞的问题>

### ❌ 阻塞项
- <必须修复才能继续的问题>

注意事项

  • 如果有阻塞项,回到步骤 5 修复后再继续
  • 重点检查计划.md 中的验收标准是否全部满足
  • 涉及 UI 时,位置/文案以 PRD 截图为准;计划.md 若与截图冲突或漏写,回原图核对并按图修正
  • 测试质量检查重点看公共接口,不深入内部实现
  • 自测不需要跑性能测试(除非计划.md 中明确要求)
Changes

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.

  1. 1mo ago First seen · 117 lines · 26 tokens per session scan A 496b043ba38d

Subscribe to this mod's changes

self-test is a skill published in the GitHub repository Today-Hbw/claude-code-dev-workflow (23 stars, last pushed 2mo ago), licensed MIT. It adds 26 tokens to every session and 1,170 once invoked, about $0.0001 per session on Opus 5.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.

Related

Other skills, from other repositories

ai-prompt-regression-testing

Use when comparing prompt changes against a fixed evaluation set: record actual model settings, required checks, missing results, judge limitations and case-level regression evidence.

sickn33/agentic-awesome-skills · 37 tokens

promptfoo-redteam-setup

Create or refine a Promptfoo redteam config and generate probes from target behavior, code, or OpenAPI evidence. Use for purpose, trust boundaries, plugins, strategies, and grading guidance. Use promptfoo-provider-setup for connection work and promptfoo-redteam-run for an existing scan.

promptfoo/promptfoo · 65 tokens

promptfoo-provider-setup

Connect Promptfoo to a model, live HTTP API, local Python/JavaScript provider, or app code. Use for request/auth mapping, response parsing, OpenAPI setup, and connection smoke tests. Use promptfoo-evals for broader eval coverage and promptfoo-redteam-setup for attack selection.

promptfoo/promptfoo · 66 tokens

promptfoo-redteam-run

Execute, inspect, and rerun an existing Promptfoo redteam scan. Use for generated YAML, result exports, attack success rates, grader/target errors, filtered reruns, and CI gates. Use promptfoo-provider-setup for connections and promptfoo-redteam-setup for new scan plans.

promptfoo/promptfoo · 66 tokens

discount-review

Inspect the discount policy fixture with a repeatable review checklist and helper script.

promptfoo/promptfoo · 18 tokens

code-review

Reviews code for bugs, security issues, and best practices.

promptfoo/promptfoo · 11 tokens