testing-strategy

testing-strategy is a skill for Claude Code, Codex from kouroshez/coding-os. It costs 118 tokens per session (3,248 once invoked), scanned A, original, Apache-2.0.

A guide for choosing and organising software tests, from small unit tests to full end-to-end checks.

In plain words
What is it for?
Use it when adding tests for features or bug fixes, reviewing test coverage, investigating flaky or slow tests, or moving manual checks into automated CI.
Why use it?
It helps prevent testing too much at one level, which can make a test suite slow, unreliable, or poor at finding real bugs.

Skill for Claude CodeCodex

Written for no agent in particular: nothing here depends on one.

Good fit Use it when adding tests for features or bug fixes, reviewing test…

Compare 6 skills from other repositories ↓
Install with agentmods
npx agentmods add skills/kouroshez/coding-os/testing-strategy
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 kouroshez/coding-os --skill testing-strategy
Clone the repo
git clone --depth 1 https://github.com/kouroshez/coding-os

Made for: Claude Code, Codex.

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 testing-strategy

README.md
[![agentmods](https://agentmods.dev/badge/skills/kouroshez/coding-os/testing-strategy.svg)](https://agentmods.dev/skills/kouroshez/coding-os/testing-strategy)
Your own site
<a href="https://agentmods.dev/skills/kouroshez/coding-os/testing-strategy"><img src="https://agentmods.dev/badge/skills/kouroshez/coding-os/testing-strategy.svg" alt="Measured on agentmods" height="20"></a>
Per session 118 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 3,248 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 1 finding. A grade says what 26 rules found in the file — not that it is safe.
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.00118 $0.03248
Opus 5 $0.00059 $0.01624
Sonnet 5 $0.00024 $0.00650
Haiku 4.5 $0.00012 $0.00325

Measured 3d ago against content hash 2562eb43b596, method: parsed. Prices are Anthropic first-party input rates as of 2026-09-06, from the pricing page.

Security

Grade A, and why

testing-strategy scanned grade A with 1 finding 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 3d ago.

The scan reads SKILL.md. This mod also ships 1 executable file (scripts/coverage_gate.py), listed below but not scanned — reading those needs a real analyzer, not pattern matching.

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.

Makes network callslowCapability

Not a fault in itself. Listed so you know the mod talks to something, and to what.

End-to-end through a real browser (Playwright) / real mobile device (Detox / Maestro) / real API (curl-style integration). They are slow and flaky, so **keep them few and intentional**.
src/core/skills/testing-strategy/SKILL.md · 267 lines

How it starts

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

Testing Strategy — Pick the Right Layer

A practical playbook for designing test suites that catch real bugs without the suite itself becoming the bug. Stack-agnostic core; concrete recipes target this project's languages.

When to Use This Skill

  • Adding the first test to a new module — the shape you ship now sets the suite's trajectory.
  • Reviewing a PR where the test ratio looks off (e.g. all unit, no contract; all e2e, no unit).
  • Investigating a flaky / slow suite — the cure is almost never "add retries".
  • Deciding coverage targets for a service (90% lines is the wrong target).
  • Adding tests to a bug fix — the fix without a regression test will return.
  • Migrating from manual QA → automated CI.

Skip when: writing throwaway exploration code. Real code, real tests.

The Test Pyramid (still right, refined for 2026)

                ┌─────────┐
                │   E2E   │  ~5%   slow,    flake-prone, golden-path
            ┌───┴─────────┴───┐
            │   Contract +    │  ~15%  pact, OpenAPI, GraphQL schema
            │   Integration   │
        ┌───┴─────────────────┴───┐
        │                          │
        │      Unit + Property     │  ~80%  fast (ms), deterministic
        │                          │
        └──────────────────────────┘

Targets are guidance, not law. A library has more unit + property than a deployment-heavy SaaS. A regulated app has more contract + integration than a hackathon prototype. What stays constant: most tests are fast; few tests are slow; zero tests are flaky.

The Six Layers — When Each Pays Off

Layer Speed Catches Use For
Unit <10ms Logic bugs, edge cases Pure functions, calculators, parsers, mappers
Property-based <100ms Bugs you didn't think of Invariants, parsers, encoders, ordering rules
Integration <1s Wiring bugs DB queries (real DB, not mock), service composition
Contract <100ms Producer/consumer drift API schemas, MCP envelope, event payloads
E2E 5–60s Full-stack regressions One golden path per critical user flow
Smoke / run-the-deliverable seconds Import/entry crashes the unit suite hides (e.g. ModuleNotFoundError when run as a file) Every new runnable entrypoint — --help / --dry-run / python -c "import x", from the same entry the user or cron uses
Mutation / Fuzz minutes (offline) Tests that don't actually test Quarterly audit, security-critical code

Read the full file on GitHub · 267 lines

Files

What ships with it

3 files beside SKILL.md in the same directory: the scripts, references and assets a skill reads on demand. Not counted in the per-session cost; read them before you install if any of them is executable.

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. 3d ago First seen · 267 lines · 118 tokens per session scan A 2562eb43b596

Subscribe to this mod's changes

testing-strategy is a skill published in the GitHub repository kouroshez/coding-os (6 stars, last pushed 6d ago), licensed Apache-2.0. It adds 118 tokens to every session and 3,248 once invoked, about $0.0006 per session on Opus 5. A static security scan graded it A with 1 finding (makes network calls). No closer match exists in the catalogue, so it is treated as the original; first seen 2026-09-03.

Related

Other skills, from other repositories

tdd-workflow

Use this skill when writing new features, fixing bugs, or refactoring code. Enforces test-driven development with 80%+ coverage including unit, integration, and E2E tests.

affaan-m/ECC · 43 tokens

memstack-development-test-writer

Use this skill when the user says 'write tests', 'add tests', 'test coverage', 'unit tests', 'integration tests', 'component tests', 'mocking', 'edge cases', or needs to generate tests with proper mocking and edge case coverage. Do NOT use for refactoring plans or database migrations.

cwinvestments/memstack · 70 tokens

test-commander

Generate unit, integration, E2E, and visual regression tests following the Testing Trophy methodology (80% integration). Covers Vitest/Jest, Testing Library, Playwright, MSW for API mocking, snapshot strategy, visual regression (Chromatic/Percy/Playwright), test factories with Faker, and CI sharding. Use when user…

EliasOulkadi/shokunin · 117 tokens

mandu-testing

Testing patterns for Mandu applications. Use when writing unit tests, integration tests, or E2E tests. Triggers on test, spec, Bun test, Playwright, or testing tasks.

konamgil/mandu · 42 tokens

redbar.fix

Write the missing tests for the gaps redbar found, following the canonical standard for that layer (Playwright's best practices for e2e, Vitest/Jest idiom for unit, Testcontainers for integration). Reads .redbar/gaps.json, writes one test file per gap, RUNS each test it wrote, and never leaves a failing test behind …

emersonjds/redbar · 113 tokens

redbar.init

Set a project up so redbar can inspect it. Detects the language and the test runner it actually uses, then proposes the test libraries that are missing (unit, integration, e2e) and prints the exact install command. It NEVER installs anything and never edits a manifest — the human approves and runs the command. Use…

emersonjds/redbar · 96 tokens