Claude-code-customes test
Advanced test implementation command with unit/E2E support, auto-execution, and smart fixing capabilities
install
source · Clone the upstream repo
git clone https://github.com/sc30gsw/claude-code-customes
Claude Code · Install into ~/.claude/skills/
T=$(mktemp -d) && git clone --depth=1 https://github.com/sc30gsw/claude-code-customes "$T" && mkdir -p ~/.claude/skills && cp -r "$T/.claude/skills/test" ~/.claude/skills/sc30gsw-claude-code-customes-test && rm -rf "$T"
manifest:
.claude/skills/test/SKILL.mdsource content
Test Command
Implement comprehensive tests with optional test execution and intelligent failure fixing.
Usage
/test <target> [options]
Target Specification
| Target Type | Examples | Description |
|---|---|---|
| Component Name | , | React/Vue/Angular components |
| File Path | , | Module and utility files |
| Function Name | , | Specific functions |
| Feature Name | , | Entire feature areas |
Options
| Option | Description | Default |
|---|---|---|
| Unit test mode | ✅ |
| E2E test mode + accessibility injection | - |
| Auto-run tests with smart fixing | - |
| Verbose output mode | - |
| Coverage-focused mode (target 90%+) | - |
| Performance test mode | - |
| Watch mode | - |
| Fast mode (parallel + caching) | - |
| Specify files by glob | - |
| Exclude files by glob | - |
| Include dependency files | - |
| Test design only | - |
Tool Priorities
ALWAYS prioritize mcp__serena__ tools over default Claude Code tools:
File Operations (Serena MCP First)
- Reading files: Use
→mcp__serena__find_file
(fallback)Read - Searching patterns: Use
→mcp__serena__search_for_pattern
(fallback)Grep - Finding symbols: Use
→mcp__serena__find_symbol
(fallback)Glob
Code Analysis (Serena MCP)
- Symbol overview: Use
mcp__serena__get_symbols_overview - Symbol references: Use
mcp__serena__find_referencing_symbols - Code replacement: Use
→mcp__serena__replace_symbol_body
(fallback)Edit
Examples
# Basic Usage /test LoginComponent -e -r # E2E tests, run & fix /test utils/auth -u -r -c # High-coverage unit tests /test PaymentForm -e -v # E2E with verbose output # File Pattern Specification /test components --files="Button*" -u -r /test src --files="**/*.hook.ts" -u -c /test api --files="**/*Controller.ts" --include-deps -u -r # Performance-Focused /test heavyComponent -u -p -f --parallel=8 /test api/bulk -u -p --timeout=60
Test Implementation Flow
Unit Test Mode (-u)
- Target code analysis with Serena MCP
- Test framework detection (Jest, Vitest, Mocha)
- Test case creation: happy path, error cases, edge cases
E2E Test Mode (-e)
- Component analysis for interactive elements
- E2E framework detection (Cypress, Playwright)
- Accessibility attribute injection (data-testid, aria-label)
- E2E test case creation: page loading, user interactions, forms
Smart Fixing (-r option)
- Parse error output
- Classify errors: syntax, assertion, async, mock, E2E-specific
- Apply appropriate fixing strategy
- Re-run and iterate (max 10 attempts)
Output Report
📁 Created/Updated Files: - src/components/LoginForm.test.tsx - cypress/e2e/user-authentication.cy.ts 🧪 Implemented Test Cases: [Unit Tests] ✓ LoginForm happy path tests (3 cases) ✓ LoginForm error handling tests (2 cases) 🚀 Test Execution Results: [1st Run] ❌ 2 failures [Auto-Fix Applied] ✅ [2nd Run] ✅ All passed (9 tests) Coverage: 95.2%