一键导入
ralph
Iterative test hardening protocol. Adversarial review of tests, fix gaps, loop until clean.
用 Codex 或 Claude 帮你安装 复制这段 Prompt,粘贴到 Codex、Claude 或其他助手里,让它检查 Skill 页面并帮你完成安装。
菜单
Iterative test hardening protocol. Adversarial review of tests, fix gaps, loop until clean.
用 Codex 或 Claude 帮你安装 复制这段 Prompt,粘贴到 Codex、Claude 或其他助手里,让它检查 Skill 页面并帮你完成安装。
基于 SOC 职业分类
| name | ralph |
| description | Iterative test hardening protocol. Adversarial review of tests, fix gaps, loop until clean. |
| disable-model-invocation | true |
Use this whenever a feature, fix, or module needs comprehensive test validation. The goal is functional correctness, not line coverage vanity metrics.
RL-4 (MUST) Fix every gap found in Phase 1. Don't batch — fix one
category at a time, run go test -race ./... between each batch.
RL-5 (MUST) Every test function must have a // WHY: comment on the
first line of the test body explaining what specific behavior or regression
it guards against. One sentence. If you can't write it, the test shouldn't
exist.
func TestFindKeys_CancelsOnContextDone(t *testing.T) {
// WHY: Verifies that workers exit promptly when the context is
// cancelled — prevents goroutine leaks in normal operation.
t.Parallel()
// ...
}
RL-6 (MUST) Evaluate overall coverage qualitatively: does the test suite prove the module works as advertised? Map tests to documented behaviors and exported API surface. Missing mappings are gaps.
RL-7 (SHOULD) Add negative tests for concurrency-relevant paths: race conditions on shared counters, context cancellation during key generation, channel behavior under load.
// TODO(ralph): tags.err == nil with no output validation.TestFoo1, TestFoo2 naming — use descriptive scenario names.t.Skip() without an issue reference.crypto/ed25519).