Designing Tests
CloudAI-X/opencode-workflow
Guides test strategy, TDD/BDD approaches, test coverage planning, and testing best practices.
A skill your agent uses when choosing a testing model for a new project, auditing a test suite that is slow or provides low confidence, setting coverage targets, or writing a QA test plan for a…
$ npx skills add kid-sid/claude-spellbook --skill test-strategy -a claude-codeProject install by default; add -g for ~/.claude/skills/.
$ gh skill install kid-sid/claude-spellbook test-strategy --agent claude-codeProject scope by default; add --scope user for a personal install. Needs GitHub CLI 2.90.0 or later (public preview).
$ git clone --depth 1 https://github.com/kid-sid/claude-spellbook.git skills-src && mkdir -p .claude/skills && cp -r skills-src/skills/test-strategy .claude/skills/test-strategy && rm -rf skills-srcUse ~/.claude/skills/ instead of .claude/skills for a personal install. The folder must contain SKILL.md.
Claude Code skills documentation · loads skills from .claude/skills/
Install the "test-strategy" agent skill from https://github.com/kid-sid/claude-spellbook/tree/main/skills/test-strategy into .claude/skills/test-strategy/ in this project. Copy the whole folder (SKILL.md and every file beside it), keep the folder name "test-strategy", then confirm the skill loads.Claude Code copies the folder itself, the same result as the manual copy. Check what it changed before you commit it.
$skill-installer install https://github.com/kid-sid/claude-spellbook/tree/main/skills/test-strategyType this inside Codex. $skill-installer <name> installs a curated skill from openai/skills. The installer writes to $CODEX_HOME/skills (default ~/.codex/skills). Restart Codex if the skill does not show up.
$ npx skills add kid-sid/claude-spellbook --skill test-strategy -a codexProject install goes to .agents/skills/; add -g for ~/.codex/skills/.
$ gh skill install kid-sid/claude-spellbook test-strategy --agent codexProject scope by default (.agents/skills/); add --scope user for a personal install.
$ git clone --depth 1 https://github.com/kid-sid/claude-spellbook.git skills-src && mkdir -p .agents/skills && cp -r skills-src/skills/test-strategy .agents/skills/test-strategy && rm -rf skills-srcUse ~/.agents/skills/ instead of .agents/skills for a personal install.
Codex skills documentation · loads skills from .agents/skills/
Install the "test-strategy" agent skill from https://github.com/kid-sid/claude-spellbook/tree/main/skills/test-strategy into .agents/skills/test-strategy/ in this project. Copy the whole folder (SKILL.md and every file beside it), keep the folder name "test-strategy", then confirm the skill loads.Codex copies the folder itself, the same result as the manual copy. Check what it changed before you commit it.
$ npx skills add kid-sid/claude-spellbook --skill test-strategy -a cursorProject install goes to .agents/skills/; add -g for ~/.cursor/skills/.
$ gh skill install kid-sid/claude-spellbook test-strategy --agent cursorProject scope by default (.agents/skills/); add --scope user for a personal install.
$ git clone --depth 1 https://github.com/kid-sid/claude-spellbook.git skills-src && mkdir -p .cursor/skills && cp -r skills-src/skills/test-strategy .cursor/skills/test-strategy && rm -rf skills-srcUse ~/.cursor/skills/ instead of .cursor/skills for a personal install.
Cursor skills documentation · loads skills from .cursor/skills/, .agents/skills/, .claude/skills/, .codex/skills/
Install the "test-strategy" agent skill from https://github.com/kid-sid/claude-spellbook/tree/main/skills/test-strategy into .cursor/skills/test-strategy/ in this project. Copy the whole folder (SKILL.md and every file beside it), keep the folder name "test-strategy", then confirm the skill loads.Cursor copies the folder itself, the same result as the manual copy. Check what it changed before you commit it.
$ gemini skills install https://github.com/kid-sid/claude-spellbook.git --path skills/test-strategy--scope user (default) or --scope workspace; --path is the subfolder of the repo that holds the skill; --consent skips the security confirmation prompt.
$ npx skills add kid-sid/claude-spellbook --skill test-strategy -a gemini-cliProject install goes to .agents/skills/; add -g for ~/.gemini/skills/.
$ gh skill install kid-sid/claude-spellbook test-strategy --agent gemini-cliProject scope by default (.agents/skills/); add --scope user for a personal install.
$ git clone --depth 1 https://github.com/kid-sid/claude-spellbook.git skills-src && mkdir -p .gemini/skills && cp -r skills-src/skills/test-strategy .gemini/skills/test-strategy && rm -rf skills-srcUse ~/.gemini/skills/ instead of .gemini/skills for a personal install, then run /skills reload.
Gemini CLI skills documentation · loads skills from .gemini/skills/, .agents/skills/
Install the "test-strategy" agent skill from https://github.com/kid-sid/claude-spellbook/tree/main/skills/test-strategy into .gemini/skills/test-strategy/ in this project. Copy the whole folder (SKILL.md and every file beside it), keep the folder name "test-strategy", then confirm the skill loads.Gemini CLI copies the folder itself, the same result as the manual copy. Check what it changed before you commit it.
$ gh skill install kid-sid/claude-spellbook test-strategyInstalls for Copilot at project scope by default; add --scope user for a personal install. Preview a skill first with gh skill preview. Needs GitHub CLI 2.90.0 or later (public preview).
$ npx skills add kid-sid/claude-spellbook --skill test-strategy -a github-copilotProject install goes to .agents/skills/; add -g for ~/.copilot/skills/.
$ git clone --depth 1 https://github.com/kid-sid/claude-spellbook.git skills-src && mkdir -p .github/skills && cp -r skills-src/skills/test-strategy .github/skills/test-strategy && rm -rf skills-srcUse ~/.copilot/skills/ instead of .github/skills for a personal install. Commit .github/skills so cloud agent and code review can use it.
GitHub Copilot skills documentation · loads skills from .github/skills/, .claude/skills/, .agents/skills/
Install the "test-strategy" agent skill from https://github.com/kid-sid/claude-spellbook/tree/main/skills/test-strategy into .github/skills/test-strategy/ in this project. Copy the whole folder (SKILL.md and every file beside it), keep the folder name "test-strategy", then confirm the skill loads.GitHub Copilot copies the folder itself, the same result as the manual copy. Check what it changed before you commit it.
$ npx skills add kid-sid/claude-spellbook --skill test-strategy -a opencodeOpenCode documents no install command of its own. Project install goes to .agents/skills/; add -g for ~/.config/opencode/skills/.
$ gh skill install kid-sid/claude-spellbook test-strategy --agent opencodeProject scope by default (.agents/skills/); add --scope user for a personal install.
$ git clone --depth 1 https://github.com/kid-sid/claude-spellbook.git skills-src && mkdir -p .opencode/skills && cp -r skills-src/skills/test-strategy .opencode/skills/test-strategy && rm -rf skills-srcUse ~/.config/opencode/skills/ instead of .opencode/skills for a personal install.
OpenCode skills documentation · loads skills from .opencode/skills/, .claude/skills/, .agents/skills/
Install the "test-strategy" agent skill from https://github.com/kid-sid/claude-spellbook/tree/main/skills/test-strategy into .opencode/skills/test-strategy/ in this project. Copy the whole folder (SKILL.md and every file beside it), keep the folder name "test-strategy", then confirm the skill loads.OpenCode copies the folder itself, the same result as the manual copy. Check what it changed before you commit it.
test-strategyA skill your agent uses when choosing a testing model for a new project, auditing a test suite that is slow or provides low confidence, setting coverage targets, or writing a QA test plan for a…
Test Strategy is an agent skill from kid-sid/claude-spellbook. Use when choosing a testing model for a new project, auditing a test suite that is slow or provides low confidence, setting coverage targets, or writing a QA test plan for a release.
Its SKILL.md is about 2.7k tokens, which your agent loads only when the skill is triggered. It is a single SKILL.md file with no bundled scripts.
It sits in Testing & QA, covering Test generation, Test strategy and Microservices. The repository describes itself as: A curated collection of skills, prompts, and workflows that extend Claude's capabilities — your personal grimoire for AI-powered development. The licence is MIT.
Read from SKILL.md and the folder at commit a7c2ac9. It shows what the files ask for, not the result of running them.
Pre-approves nothing: there is no allowed-tools line, so your agent's usual permission prompts apply.
From allowed-tools in the SKILL.md frontmatter.
Shell commands in SKILL.md call:
gogitFrom the folder's file list and the shell code blocks in SKILL.md.
Hosts in commands or code, which the agent is likely to contact:
github.comFrom URLs in SKILL.md, links to its own repository left out.
Names no API keys, tokens, secrets or passwords.
From names ending in _API_KEY, _TOKEN, _SECRET, _KEY or _PASSWORD in SKILL.md.
Test Strategy loads about 2.7k tokens when it runs. Until then it costs about 49 tokens; SKILL.md has 841 words of instructions outside code blocks.
Estimates: characters ÷ 4, the usual rule of thumb; real counts depend on the model's tokenizer. Scripts and assets cost tokens only if the agent reads them.
The automated check found no risky patterns in SKILL.md.
Automated static check — not a guarantee. Review scripts before installing. It scans the text of SKILL.md for risky patterns (piping downloads into a shell, reading credential files, hidden Unicode, destructive commands); files beside SKILL.md are not scanned.
The full file from kid-sid/claude-spellbook at commit a7c2ac9, republished under its MIT licence (© kid-sid). 841 words, ~2,656 tokens.
.claude/skills/test-strategy/SKILL.md (or your agent's skills folder).Design a complete testing strategy for any project: choose the right model, set meaningful coverage targets, shift quality left, and plan non-functional testing.
Choosing the right testing model is the first decision. Each reflects a different philosophy about where confidence comes from.
/\
/E2E\ few (slow, fragile)
/------\
/ Integ \ some
/------------\
/ Unit \ many (fast, reliable)
/-----------------\ /\
/E2E\ few
/------\
/ \
/ Integra- \ most ← emphasis here
/ tion \
/---------\
/ Unit \ some
/ (static) \ type checking, linting| Context | Recommended Model | Reason |
|---|---|---|
| Monolith, complex business logic | Pyramid | Units test business rules cheaply |
| Frontend-heavy application | Trophy | Integration tests reflect user behavior |
| Microservices (many small services) | Honeycomb | Service integration > unit isolation |
| Data pipeline | Custom (mostly integration) | Units are trivial; real data matters |
| Metric | What It Measures | How to Get It |
|---|---|---|
| Line coverage | Were these lines executed? | --cov, --coverage, go test -cover |
| Branch coverage | Were all if/else paths taken? | --branch flag |
| Mutation coverage | Do tests catch logic mutations? | mutmut (Python), stryker (TS), go-mutesting |
| Codebase Type | Line Coverage Target | Notes |
|---|---|---|
| New greenfield project | 80%+ | Enforce from day 1 |
| Adding tests to legacy | Raise by 5% per sprint | Ratchet: never let it drop |
| Critical path (payments, auth) | 95%+ | Include branch coverage |
| Generated code, migrations, config loaders | Exclude from measurement | Noisy, not meaningful |
Rule: coverage is a floor, not a goal. 60% with excellent integration tests > 100% with trivial mocks.
# pytest example (pyproject.toml)
[tool.pytest.ini_options]
addopts = "--cov=src --cov-fail-under=80 --cov-branch"
[tool.coverage.report]
omit = ["src/migrations/*", "src/generated/*", "**/config_loader.py"]// Jest example (package.json)
{
"jest": {
"coverageThreshold": {
"global": {
"lines": 80,
"branches": 70
}
},
"coveragePathIgnorePatterns": ["/generated/", "/migrations/"]
}
}// Go example (Makefile)
// go test ./... -coverprofile=coverage.out && go tool cover -func=coverage.out | grep totalShift-left = catch defects earlier in the development cycle (before code review, before CI).
| Technique | When It Runs | What It Catches |
|---|---|---|
| Type checking (mypy, tsc, go vet) | IDE + pre-commit | Type errors, wrong function signatures |
| Linting (ruff, eslint, staticcheck) | IDE + pre-commit | Style, common bugs, dead code |
| Pre-commit hooks | On git commit | Both above, secret scanning |
| Contract tests | CI on PR | API contract violations between services |
| Property-based tests | CI | Edge cases the developer didn't think of |
# .pre-commit-config.yaml
repos:
- repo: https://github.com/astral-sh/ruff-pre-commit
rev: v0.3.0
hooks:
- id: ruff
- id: ruff-format
- repo: https://github.com/pre-commit/mirrors-mypy
rev: v1.9.0
hooks:
- id: mypy
- repo: https://github.com/Yelp/detect-secrets
rev: v1.4.0
hooks:
- id: detect-secretsContract tests verify that two services agree on the shape of requests and responses without needing both services running simultaneously.
// Consumer side (TypeScript/Pact)
const interaction = {
state: "user 123 exists",
uponReceiving: "a request for user 123",
withRequest: { method: "GET", path: "/users/123" },
willRespondWith: {
status: 200,
body: { id: 123, name: like("Alice") },
},
};# Python / Hypothesis
from hypothesis import given, strategies as st
@given(st.lists(st.integers()))
def test_sort_is_idempotent(lst):
assert sorted(sorted(lst)) == sorted(lst)| Type | What It Tests | Tools | When to Run |
|---|---|---|---|
| Load testing | Behavior under expected traffic | k6, Locust, JMeter | Pre-launch, nightly |
| Stress testing | Behavior beyond capacity | k6, Gatling | Before scaling decisions |
| Soak testing | Behavior over extended time (memory leaks) | k6, Locust | Weekly |
| Spike testing | Sudden traffic burst handling | k6 | Before big events |
| Security testing | Vulnerability scanning | OWASP ZAP, Snyk, pip-audit | Every CI run (SAST), nightly (DAST) |
| Accessibility (a11y) | WCAG compliance | axe-core, Playwright + axe | Every PR for UI changes |
| Visual regression | Unintended UI changes | Playwright screenshots, Percy | Every PR for UI changes |
// k6 load test
import http from "k6/http";
import { check, sleep } from "k6";
export const options = {
stages: [
{ duration: "1m", target: 50 }, // ramp up
{ duration: "3m", target: 50 }, // hold
{ duration: "1m", target: 0 }, // ramp down
],
thresholds: {
http_req_duration: ["p(95)<500"], // 95th percentile under 500ms
http_req_failed: ["rate<0.01"], // error rate under 1%
},
};
export default function () {
const res = http.get("https://api.example.com/health");
check(res, { "status is 200": (r) => r.status === 200 });
sleep(1);
}// Playwright + axe-core
import { test, expect } from "@playwright/test";
import AxeBuilder from "@axe-core/playwright";
test("homepage has no WCAG violations", async ({ page }) => {
await page.goto("/");
const results = await new AxeBuilder({ page })
.withTags(["wcag2a", "wcag2aa"])
.analyze();
expect(results.violations).toEqual([]);
});# Test Plan: [Feature / Release Name]
## Scope
What is being tested:
- [Feature 1]
- [Feature 2]
## Out of Scope
- [Explicitly excluded items]
## Test Environments
| Environment | URL | Data State |
|-------------|-----|-----------|
| Staging | ... | Anonymized copy of prod |
## Test Types and Owners
| Type | Owner | Tools | When |
|------|-------|-------|------|
| Unit | Dev | pytest/Jest/Go test | Every PR |
| Integration | Dev | Testcontainers | Every PR |
| E2E smoke | QA | Playwright | Post-deploy |
| Load | SRE | k6 | Pre-launch |
## Entry Criteria
- [ ] Feature code merged to main
- [ ] CI green
## Exit Criteria
- [ ] All P0/P1 test cases pass
- [ ] No open CRITICAL/HIGH bugs
- [ ] Coverage >= 80%
- [ ] Smoke tests pass on staging
## Risk Areas
| Risk | Likelihood | Impact | Mitigation |
|------|-----------|--------|-----------|
| ... | ... | ... | ... |See also:
unit-testing,integration-testing,solution-testing,performance-testing
© kid-sid, MIT. Rendered from Markdown: HTML in the file is shown as text, images as links, and headings moved down two levels. Raw file
Just SKILL.md in skills/test-strategy of kid-sid/claude-spellbook.
Open the folder on GitHubat commit a7c2ac9
Test Strategy next to the 5 skills that share the most tags, products or categories with it. Stars are the repository's; “used in” counts other GitHub owners with a copy.
| Skill | Stars | Used in | Tokens | Auto-check | Licence | Repo updated |
|---|---|---|---|---|---|---|
| Test Strategy this skillkid-sid/claude-spellbook | 189 | — | ~2.7k | Automated safety check: Pass | MIT | |
| Designing TestsCloudAI-X/opencode-workflow | 275 | — | ~2.9k | Automated safety check: Pass | MIT | |
| Test Strategynurettincoban/ai-prd-workflow | 298 | — | ~1.4k | Automated safety check: Pass | MIT | |
| Bmad Testarch Test Designbmad-code-org/bmad-method-test-architecture-enterprise | 104 | 3 repos | ~1.4k | Automated safety check: Pass | Custom licence | |
| Automated Test Planningtestdouble/han | 279 | — | ~6.7k | Automated safety check: Pass | MIT | |
| Bmad Tea Testarch Test Designchenjackle45/SayIt | 114 | — | ~231 | Automated safety check: Pass | MIT |
CloudAI-X/opencode-workflow
Guides test strategy, TDD/BDD approaches, test coverage planning, and testing best practices.
nurettincoban/ai-prd-workflow
Write TEST-STRATEGY.md, a test plan per RFC, before the tests are written.
bmad-code-org/bmad-method-test-architecture-enterprise
Create system-level or epic-level test plans. An agent skill from bmad-code-org/bmad-method-test-architecture-enterprise.
testdouble/han
Produce a standalone test plan by analyzing code for test coverage gaps and edge cases.
chenjackle45/SayIt
Create system-level or epic-level test plans. An agent skill from chenjackle45/SayIt.
testdouble/han
Produce a plain-language manual test plan from the context supplied to it — an executive summary, a high-level list of named tests, and a detail section per test with the steps a person follows by…
kid-sid/claude-spellbook
A skill your agent uses when building or reviewing UI components for keyboard and screen reader compatibility, adding ARIA to custom widgets, auditing a page for WCAG AA conformance, or preparing…
kid-sid/claude-spellbook
A skill your agent uses when building, wiring, or debugging an Agentex agent — choosing agent type, configuring acp.py and manifest.yaml, using adk.messages or adk.state, or resolving…
kid-sid/claude-spellbook
A skill your agent uses when building production LLM applications — designing RAG pipelines, choosing vector databases, implementing agent orchestration, optimizing cost, or adding AI safety…
kid-sid/claude-spellbook
A skill your agent uses when building or refactoring Angular applications — choosing between signals, RxJS, and NgRx for state, configuring routing with guards and lazy loading, optimizing change…
kid-sid/claude-spellbook
A skill your agent uses when designing new REST endpoints, reviewing an existing API contract, adding pagination or filtering, planning a versioning strategy, or building a public or partner-facing…
kid-sid/claude-spellbook
A skill your agent uses when implementing login flows, issuing or validating JWTs, setting up OAuth2/OIDC with a provider, designing role-based or attribute-based access control, securing API…
Categories
A skill your agent uses when choosing a testing model for a new project, auditing a test suite that is slow or provides low confidence, setting coverage targets, or writing a QA test plan for a…. Test Strategy is an agent skill from kid-sid/claude-spellbook. Use when choosing a testing model for a new project, auditing a test suite that is slow or provides low confidence, setting coverage targets, or writing a QA test plan for a release.
Test Strategy fits situations like: choosing a testing model for a new project; auditing a test suite that is slow; provides low confidence; setting coverage targets.
Run `npx skills add kid-sid/claude-spellbook --skill test-strategy -a claude-code`. Or copy the skill folder (skills/test-strategy in kid-sid/claude-spellbook) into .claude/skills/test-strategy in your project. Claude Code loads it when a task matches its description.
Run `npx skills add kid-sid/claude-spellbook --skill test-strategy -a codex`. Or copy the skill folder (skills/test-strategy in kid-sid/claude-spellbook) into .agents/skills/test-strategy in your project. Codex loads it when a task matches its description.
Cursor, Gemini CLI, GitHub Copilot and OpenCode also load SKILL.md folders. With the skills CLI, run `npx skills add kid-sid/claude-spellbook --skill test-strategy -a cursor` (or -a gemini-cli, github-copilot or opencode for the others). To copy it by hand, put the folder in .cursor/skills/test-strategy, .gemini/skills/test-strategy, .github/skills/test-strategy and .opencode/skills/test-strategy in your project.
Going by SKILL.md and its folder, Test Strategy needs the command-line tools its instructions call (go and git). Our summary lists: Python 3.
SKILL.md names 1 domain. In commands or code: github.com; the agent is likely to contact it when it follows the instructions. This is read from the text; nothing was executed.
Our automated static check of SKILL.md found no risky patterns, such as piping downloads into a shell, reading credential files or hidden Unicode. It is not a guarantee. Review the folder before installing.
Test Strategy is published under the MIT licence (the repository's licence). It allows redistribution, so the full SKILL.md is shown on this page.
About 2.7k tokens (SKILL.md is roughly 11k characters). Agents keep only the skill's name and description in context until a task matches; then they load SKILL.md in full.
Skills that share tags, products or a category with Test Strategy: Designing Tests (CloudAI-X/opencode-workflow, 275 stars), Test Strategy (nurettincoban/ai-prd-workflow, 298 stars), Bmad Testarch Test Design (bmad-code-org/bmad-method-test-architecture-enterprise, 104 stars) and Automated Test Planning (testdouble/han, 279 stars). The comparison table on this page puts their stars, adoption, token cost, safety result and licence side by side.
kid-sid (a GitHub user) maintains it in kid-sid/claude-spellbook, which has 189 GitHub stars. The repository holds 52 skills in this directory. The repository was last updated on August 5, 2026.
Source: kid-sid/claude-spellbook on GitHub. Facts on this page come from the repository at the commit we read; the author's words are quoted as theirs.