Skip to content
Development
Skill

/unit-test

Unit testing techniques, mocking, and assertions

From plugin
pudo-code-system
534 skills1 agent
Install
$ npx -y skills add DongDuong2001/pudo-code-system --skill unit-test --agent claude-code

How it fires

How this skill gets triggered: by you, by Claude, or both.

  • Fires itselfAuto-invocation. Claude auto-loads it when your prompt matches the work.Auto-invocation is when the right skill fires by itself at the right moment, driven by a FLOW.md router and a hook, instead of you invoking it by name. It is the difference between a skill being installed and a skill actually getting used.Read the full definition →
  • You can call itInvoke it directly when you want it.
  • Slash command/unit-test

Context preview

The summary Claude sees to decide when to auto-load this skill.

Unit testing techniques, mocking, and assertions

SKILL.md

unit-test.SKILL.md
name: unit-test
description: Unit testing techniques, mocking, and assertions

Unit Test Skill

This skill focuses on writing fast, isolated tests for individual units of code (functions, methods, classes).

When to use this skill

  • When writing tests for utility functions, algorithms, or standalone classes.
  • When using tools like Jest, pytest, JUnit, or xUnit.
  • When needing to mock out dependencies (databases, APIs, file systems).

Guidelines

  • **Isolation:** A unit test should not rely on an external database or network. Use mocks or stubs instead.
  • **Naming:** Use clear, descriptive names (e.g., `calculateTotal_withValidInput_returnsCorrectSum`).
  • **Structure:** Use the Arrange-Act-Assert (AAA) pattern.
  • **Speed:** Unit tests must be fast so developers can run them frequently.
Ships withpudo-code-system

Modular, scalable, automated development intelligence.

Get the whole plugin
Stats
5
Stars
0
Forks
Maintained
Maintenance
JavaScript
Language
MIT
License
1mo ago
Last commit
4mo ago
Created

Repo: DongDuong2001/pudo-code-system

Other skills on pudo-code-system.