ownyourcode: Skill for Claude Code

.claude/skills/fundamentals/testing/SKILL.md

testing-fundamentals is a skill for Claude Code from DanielPodolsky/ownyourcode. It costs 67 tokens per session (1,469 once invoked), scanned A, original, MIT.

A guide to planning and reviewing software tests, from small checks of individual functions to tests of complete user journeys. It explains unit, integration, and end-to-end tests and covers tools such as Vitest, Jest, Playwright, pytest, and Go's test tools.

In plain words
What is it for?
Use it when writing or reviewing tests, deciding what to test, checking coverage, choosing testing tools, or learning patterns such as Arrange-Act-Assert and test doubles.
Why use it?
It helps decide what needs testing and which kind of test fits the job, so teams do not rely only on slow full-application checks or miss important cases.

Skill for Claude Code

Written for Claude Code: installed under .claude/.

This is DanielPodolsky/ownyourcode's own configuration. It tells Claude Code how to work on ownyourcode itself, so it is not a mod to install elsewhere. Copy it as a starting point and replace the rules that are about this project. Everything ownyourcode configures →

Reuse

Borrowing it

Nothing to install: this file belongs to DanielPodolsky/ownyourcode. Take a copy, put it at the same path in your own repository, and replace the rules that are about this project with yours.

Copy the file
curl -O https://raw.githubusercontent.com/DanielPodolsky/ownyourcode/main/.claude/skills/fundamentals/testing/SKILL.md
Clone the repo
git clone --depth 1 https://github.com/DanielPodolsky/ownyourcode

Made for: Claude Code.

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-fundamentals

README.md
[![agentmods](https://agentmods.dev/badge/skills/danielpodolsky/ownyourcode/testing/github.svg)](https://agentmods.dev/skills/danielpodolsky/ownyourcode/testing)
Your own site
<a href="https://agentmods.dev/skills/danielpodolsky/ownyourcode/testing"><img src="https://agentmods.dev/badge/skills/danielpodolsky/ownyourcode/testing/github.svg" alt="Measured on agentmods" height="20"></a>

Or the 80×15 button, for a site that already has a row of RSS and ATOM ones. Only the verdict fits; the numbers stay here.

agentmods 80×15 button for testing-fundamentals

Your own site · 80×15
<a href="https://agentmods.dev/skills/danielpodolsky/ownyourcode/testing"><img src="https://agentmods.dev/badge/skills/danielpodolsky/ownyourcode/testing.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 67 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 1,469 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. A grade says what 26 rules found in the file — not that it is safe. Third-party audits
  • NVIDIA SkillSpector pass 7 Sept 2026
How audits are shown
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.00067 $0.01469
Opus 5.5 $0.00027 $0.00588
Sonnet 5.5 $0.00013 $0.00294
Haiku 4.5 $0.00007 $0.00147

Measured 1mo ago against content hash ceb4ef6b6524, method: parsed. Prices are Anthropic first-party input rates as of 2026-10-07, from the pricing page.

Security

Grade A, and why

testing-fundamentals 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 1mo 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.

.claude/skills/fundamentals/testing/SKILL.md · 219 lines

How it starts

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

Testing Fundamentals Review

"If you can't test it, you don't understand it. Tests are proof of understanding."

When to Apply

Activate this skill when:

  • Reviewing test files (*.test.ts, *.spec.ts, *.test.js)
  • Junior asks about testing strategy
  • Completing a feature without tests
  • Discussing coverage or test quality

The Testing Pyramid

        ▲
       ╱ ╲     E2E (10%)
      ╱   ╲    Playwright - Full user flows
     ╱─────╲
    ╱       ╲  Integration (20%)
   ╱         ╲ Vitest + RTL - Component interactions
  ╱───────────╲
 ╱             ╲ Unit (70%)
╱               ╲ Vitest - Functions, utils, logic
─────────────────
  • Unit Tests (70%): Fast, isolated, test one thing
  • Integration Tests (20%): Components working together
  • E2E Tests (10%): Critical user journeys only

Stack-Specific Framework Guide

Stack Unit/Integration E2E
Vite + React Vitest + React Testing Library Playwright
Create React App Jest + RTL Playwright
Next.js Vitest or Jest + RTL Playwright
Node.js Vitest (native ESM) -
Python pytest -
Go go test -

Why Vitest for Vite?

  • 10-20x faster than Jest in watch mode
  • Native ESM support
  • Same config as Vite (vite.config.ts)
  • Compatible with Jest API

What to Test (The 3 Questions)

  1. Happy Path: Does it work when everything goes right?
  2. Edge Cases: What happens with empty, null, max values?
  3. Error States: Does it fail gracefully?

Good Tests Check:

  • Component renders without crashing
  • User interactions work (click, type, submit)
  • Error states display correctly
  • Loading states appear and disappear
  • Data flows correctly through the component

Bad Tests Check:

  • Implementation details (internal state, method calls)
  • Styling or CSS classes
  • Third-party library internals
  • Snapshot tests of large components (brittle)

Common Mistakes (Anti-Patterns)

Read the full file on GitHub · 219 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. 1mo ago First seen · 219 lines · 67 tokens per session scan A ceb4ef6b6524

Subscribe to this mod's changes

testing-fundamentals is a skill published in the GitHub repository DanielPodolsky/ownyourcode (292 stars, last pushed 4mo ago), licensed MIT. It adds 67 tokens to every session and 1,469 once invoked, about $0.0003 per session on Opus 5.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.