1.3 KiB
1.3 KiB
description, allowed-tools, argument-hint
| description | allowed-tools | argument-hint | |
|---|---|---|---|
| Generate and run tests for code - creates comprehensive test suites | Read(*), Write(*), Grep(*), Glob(*), Bash(*) |
|
Test Command
Generate comprehensive tests or run existing tests.
Technology Adaptation
Configuration Source: CLAUDE.md
Consult CLAUDE.md for:
- Test Framework: (xUnit, Jest, pytest, JUnit, Go test, Rust test, etc.)
- Test Command: How to run tests
- Test Location: Where tests are stored
- Coverage Tool: Code coverage command
Instructions
-
Read CLAUDE.md for test framework and patterns
-
Determine Action
- If code file in $ARGUMENTS: Generate tests for it
- If test file in $ARGUMENTS: Run that test
- If directory in $ARGUMENTS: Run all tests in directory
- If no argument: Run all project tests
-
For Test Generation
- Analyze code to identify test cases
- Generate tests covering happy paths, edge cases, errors
- Follow CLAUDE.md test patterns
- Use test-engineer agent for complex scenarios
-
For Test Execution
- Use test command from CLAUDE.md
- Display results clearly
- Show coverage if available
MCP Usage
- serena:
find_symbolto analyze code structure - context7:
get-library-docsfor testing best practices