testing-strategy

A method for choosing the smallest test that can prove a required behavior, from a local unit test to a full end-to-end user journey.

In plain words
What is it for?
It helps decide whether requirements need unit, integration, or end-to-end testing by examining the observable result, existing coverage, setup cost, and maintenance effort.
Why use it?
It prevents costly or fragile integration and browser tests when a simpler existing check is enough.

Skill for Claude CodeCodex

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.

agentmods
npx agentmods add skills/shinpr/agentic-code/testing-strategy
Any agent
npx skills add shinpr/agentic-code --skill testing-strategy
Clone the repo
git clone --depth 1 https://github.com/shinpr/agentic-code

Made for: Claude Code, Codex.

Per session 32 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 485 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. Scan, not verified.
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 $0.00032 $0.00485
Opus 5 $0.00016 $0.00243
Sonnet 5 $0.00006 $0.00097
Haiku 4.5 $0.00003 $0.00049

Measured 2d ago against content hash 39a5a74cdef5, method: parsed. Prices are Anthropic first-party input rates as of 2026-08-30, from the pricing page.

Security

Grade A, and why

testing-strategy 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 2d 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.

.agents/skills/testing-strategy/SKILL.md · 64 lines

How it starts

The opening of the file, as written. The whole thing — 64 lines — stays where its author put it; the contents beside it link to each section on GitHub.

Test Strategy

Purpose

Select tests that prove an observable requirement at the lowest sufficient cost. Candidate discovery does not create an obligation to implement every technically valid test.

Selection Process

For each acceptance criterion that may require integration or E2E proof:

  1. Name the observable boundary: Identify the interaction, persisted effect, process, or user journey that must be proven.
  2. Check existing proof: Reuse or extend an established test when it already observes the required behavior.
  3. Select the narrowest level:
    • use a unit or local check for isolated behavior;
    • use integration when the requirement depends on a named component, persistence, or process boundary;
    • use E2E only when the complete journey is itself the requirement.
  4. Compare cost: Consider setup, execution time, brittleness, maintenance, and diagnostic value using repository evidence rather than fixed universal scores.
  5. Retain necessary proof: Select a test only when a cheaper boundary cannot establish the required behavior or protect an accepted contract.

No new integration or E2E test is a valid conclusion when existing or cheaper proof is sufficient.

Priority

Prioritize proof for:

  • core user or consumer journeys;
  • shared or public contracts;
  • persisted state transitions;
  • security, authorization, compliance, or irreversible effects;
  • integrations with demonstrated failure risk.

Priority does not determine test level. Use the narrowest boundary that can observe the prioritized behavior.

Deduplication

Before adding a test:

  • search the existing suite for equivalent behavior;
  • identify overlapping proof at other levels;
  • extend existing coverage when that remains clear and maintainable;
  • keep one representative proof when several candidates observe the same risk.

Selection Record

Record only decisions needed by planning or review:

Acceptance criterion: [identifier or behavior]
Selected proof: existing | local | integration | E2E | none
Boundary observed: [observable interaction or result]
Reason: [why this is the narrowest sufficient proof]

Read the full file on GitHub · 64 lines

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. 2d ago First seen · 64 lines · 32 tokens per session scan A 39a5a74cdef5

Subscribe to this mod's changes

testing-strategy is a skill published in the GitHub repository shinpr/agentic-code (49 stars, last pushed 3d ago), licensed MIT. It adds 32 tokens to every session and 485 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-08-30.