cover
БесплатноЗапускает вложенные скриптыНе проверенWrites tests that do not exist yet across unit, integration and end-to-end tiers, healing failures up to 3 times. Use when code lacks tests. Not for grading…
от yonatangross★ 312 звёзд на GitHubОб этом скилле
Cover: Test Suite Generator
Host-neutral workflow. Invoke by skill name (cover). Claude Code slash routing, YAML hook loaders, and .claude/chain live in references/claude-code.md.
Generate comprehensive test suites for existing code with real-service integration testing and automated failure healing.
Note: If
disableSkillShellExecutionis enabled (CC 2.1.91), the precondition check for vitest/jest won't run. Verify a test runner is installed before proceeding:npx vitest --versionornpx jest --version.
Quick Start
cover authentication flow
cover --model=opus payment processing
cover --tier=unit,integration user service
cover --real-services checkout pipeline
Argument Resolution
A pronoun target (this, them, the above) is read back from the conversation, announced in one line, and used: Read("../../shared/rules/target-resolution.md"), inline half.
SCOPE = "$ARGUMENTS" # e.g., "authentication flow"
# Flag parsing
MODEL_OVERRIDE = None
TIERS = ["unit", "integration", "e2e"] # default: all three
REAL_SERVICES = False
for token in "$ARGUMENTS".split():
if token.startswith("--model="):
MODEL_OVERRIDE = token.split("=", 1)[1]
SCOPE = SCOPE.replace(token, "").strip()
elif token.startswith("--tier="):
TIERS = token.split("=", 1)[1].split(",")
SCOPE = SCOPE.replace(token, "").strip()
elif token == "--real-services":
REAL_SERVICES = True
SCOPE = SCOPE.replace(token, "").strip()
Step -0.5: Effort-Aware Coverage Scaling (CC 2.1.76, env var since 2.1.120)
Read $CLAUDE_EFFORT (CC 2.1.120+) first; explicit --effort= token wins as override. Default high when CC < 2.1.120 and no flag. Pattern matches assess + explore (#1540). Scale test generation depth:
| Effort Level | Tiers Generated | Agents | maxIterations to pass Phase 5 |
|---|---|---|---|
| low | Unit only | 1 agent | 2 (1 repair + 1 verify) |
| medium | Unit + Integration | 2 agents | 2 (1 repair + 1 verify) |
| high (default) | Unit + Integration + E2E | 3 agents | 3 (2 repairs + 1 verify) |
| xhigh (CC 2.1.111+) | Unit + Integration + E2E | 3 agents | 3 (the ceiling; xhigh adds agents, not heal passes) |
Values are what you pass as maxIterations in Phase 5. The script clamps to [2, 3]
(heal-loop.js), so anything outside that range is coerced, and the final iteration always
verifies rather than repairing. There is no 4-iteration mode.
Override: Explicit
--tier=flag or user selection overrides/effortdownscaling.
Step -1: MCP Probe + Resume Check
# Probe MCPs (parallel):
# memory is alwaysLoad in .mcp.json (CC 2.1.121+, #1541). Probe below kept as fallback for older CC:
ToolSearch(query="select:mcp__memory__search_nodes")
ToolSearch(query="select:mcp__context7__resolve-library-id")
Write(".claude/chain/capabilities.json", {
"memory": <true if found>,
"context7": <true if found>,
"skill": "cover",
"timestamp": now()
})
# Resume check:
Read(".claude/chain/state.json")
# If exists and skill == "cover": resume from current_phase
# Otherwise: initialize state
Step 0: Scope & Tier Selection
AskUserQuestion(
questions=[
{
"question": "What test tiers should I generate?",
"header": "Test Tiers",
"options": [
{"label": "Full coverage (Recommended)", "description": "Unit + Integration (real services) + E2E"},
{"label": "Unit + Integration", "description": "Skip E2E, focus on logic and service boundaries"},
{"label": "Unit only", "description": "Fast isolated tests for business logic"},
{"label": "E2E only", "description": "Playwright browser tests"}
],
"multiSelect": false
},
{
"question": "Healing strategy for failing tests?",
"header": "Failure Handling",
"options": [
{"label": "Auto-heal (Recommended)", "description": "Fix failing tests up to 3 iterations"},
{"label": "Generate only", "description": "Write tests, report failures, don't fix (skips the heal loop)"},
{"label": "Strict", "description": "All tests must pass or abort"}
],
"multiSelect": false
}
]
)
Override TIERS based on selection. Skip this step if --tier= flag was provided.
Finish line. Done means: every generated test runs, the suite is green or each remaining failure is reported with its heal-loop classification, and the coverage report is written. Follow Read("../../shared/rules/long-run-protocol.md"): keep going when a step needs no input from the user, stop and ask only when you can't continue without them or before anything destructive, check each subagent's evidence before accepting it, and mark anything you couldn't confirm with where you looked.
Task Management (MANDATORY)
# 1. Create main task IMMEDIATELY
TaskCreate(subject=f"Cover: {SCOPE}", description="Gen
Установить cover в Claude Code и Claude Desktop
Зарегайся, чтобы установить скилл
Создай бесплатный аккаунт, чтобы открыть команду установки и сохранить скилл в библиотеку.
- Открой команду установки в одну строку
- Сохраняй скиллы в синхронизируемую библиотеку
- Уведомления, когда скиллы обновляются
Разрешённые инструменты
Инструменты, которые скиллу разрешено вызывать.
SendMessageAskUserQuestionBashReadWriteEditGrepGlobAgentTaskCreateTaskUpdateTaskListTaskStopToolSearchWorkflowCronCreateCronDeleteMonitorPushNotificationmcp__memory__search_nodesmcp__context7__resolve-library-idmcp__context7__query-docsВложенные файлы
FAQ
Что делает скилл cover?
Writes tests that do not exist yet across unit, integration and end-to-end tiers, healing failures up to 3 times. Use when code lacks tests. Not for grading existing tests (use verify) or running a suite.
Как установить скилл cover?
Скопируй папку скилла в ~/.claude/skills (вкладка Claude Code выше делает это одной командой), либо поставь как плагин.
Скилл cover запускает скрипты?
Да, скилл несёт исполняемые скрипты. Проверь исходник перед установкой.
Похожие скиллы
mcp-builder
Guide for creating high-quality MCP (Model Context Protocol) servers that enable LLMs to interact with external services through well-designed tools. Use when…
от Anthropicclaude-api
Reference for the Claude API / Anthropic SDK — model ids, pricing, params, streaming, tool use, MCP, agents, caching, token counting, model migration. TRIGGER…
от Anthropicalgorithmic-art
Creating algorithmic art using p5.js with seeded randomness and interactive parameter exploration. Use this when users request creating art using code…
от Anthropicmcp-integration
This skill should be used when the user asks to "add MCP server", "integrate MCP", "configure MCP in plugin", "use .mcp.json", "set up Model Context…
от Anthropic