Agent skill
software-testing
Always use this skill when writing or editing software tests!
Install this agent skill to your Project
npx add-skill https://github.com/majiayu000/claude-skill-registry/tree/main/skills/other/software-testing
SKILL.md
software-testing
- When writing tests, avoid mocking too much otherwise your tests will be unmaintainable.
- Always prefer one or two simple integration tests over a bunch of fully mocked unit tests.
- Use real models and data structures whenever possible.
- Print local variables to stdout on tests.
- Focus on inputs and outputs to make it easier to debug it when tests fail.
- Prefer running tests individually rather than the entire suite when facing errors.
- Validate using models (e.g.: pydantic) instead of countless field-by-field assertions.
data = MyDataModel(**obj)validates structure and types.- then assert
data == expected_data.
- When testing file operations (reading/writing), use
tmp_pathfixture.- Files are automatically cleaned up after the test.
- When reading Excel/CSV files for comparison with Pydantic models:
- Use
pd.read_excel(..., dtype=str, keep_default_na=False)to avoid type coercion issues. - Pandas converts numeric strings to int/float and empty cells to NaN, breaking Pydantic validation.
- Use
Recommended Agent Skills
Expand your agent's capabilities with these related and highly-rated skills.
agent-ops-spec
Manage specification documents in .agent/specs/. Use when user provides requirements, acceptance criteria, or feature descriptions that need to be tracked and validated against implementation.
agent-ops-state
Maintain .agent state files. Use at session start, after meaningful steps, and before concluding: read/update constitution/memory/focus/issues/baseline consistently.
agent-ops-spec
Manage specification documents in .agent/specs/. Use when user provides requirements, acceptance criteria, or feature descriptions that need to be tracked and validated against implementation.
agent-ops-testing
Test strategy, execution, and coverage analysis. Use when designing tests, running test suites, or analyzing test results beyond baseline checks.
agent-ops-testing
Test strategy, execution, and coverage analysis. Use when designing tests, running test suites, or analyzing test results beyond baseline checks.
agent-ops-state
Maintain .agent state files. Use at session start, after meaningful steps, and before concluding: read/update constitution/memory/focus/issues/baseline consistently.
Didn't find tool you were looking for?