2233admin/cicada/test-helper
Claude Code and agent skill by 2233admin/cicada
Trust tier 3
- community
Source check pending
Checking that the SKILL.md file is still in the repository.
Generate comprehensive test cases following TDD principles
Install
npx vskill@latest install 2233admin/cicada/test-helperSKILL.md
Test Helper
Generate high-quality test cases following Test-Driven Development (TDD) principles and best practices.
When to Activate
Explicit Triggers
- User says "write tests"
- User says "生成测试"
- User says "create test cases"
- User says "help me test this"
Implicit Triggers
- User implements a new feature without tests
- User asks about test coverage
- User mentions TDD or testing
NOT Activated For
- Running existing tests (use test runner directly)
- Debugging test failures (use debugging tools)
- Test configuration setup
Testing Principles
1. Test-Driven Development (TDD)
Always write tests BEFORE implementation:
- RED: Write a failing test
- GREEN: Write minimal code to pass
- REFACTOR: Clean up while keeping tests green
2. Test Coverage Target
- Minimum: 80% code coverage
- Focus: Critical paths, edge cases, error conditions
- Exclude: Generated code, trivial getters/setters
3. Test Quality
- Isolated: Each test independent
- Clear: Descriptive names, obvious intent
- Fast: Run quickly, no unnecessary delays
- Reliable: No flaky tests, deterministic results
Test Types
Unit Tests
Test individual functions/methods in isolation.
Integration Tests
Test interactions between components.
End-to-End Tests
Test complete user workflows.
Test Structure (AAA Pattern)
Edge Cases to Test
1. Boundary Conditions
- Empty inputs ([], "", null, undefined)
- Maximum/minimum values
- Off-by-one errors
2. Error Conditions
- Invalid inputs
- Network failures
- Database errors
- Timeout scenarios
3. Concurrent Operations
- Race conditions
- Deadlocks
- Resource contention
4. State Transitions
- Valid state changes
- Invalid state changes
- Idempotency
Test Naming Conventions
Good Names:
should return user when valid ID providedshould throw error when email already existsshould retry 3 times before failing
Bad Names:
test1it worksuser test
Mocking Best Practices
When to Mock
- External APIs
- Database connections
- File system operations
- Time-dependent code
When NOT to Mock
- Simple functions
- Internal logic
- Data structures
Test Coverage Checklist
- [ ] All public functions tested
- [ ] Happy path covered
- [ ] Error conditions tested
- [ ] Edge cases handled
- [ ] Integration points verified
- [ ] 80%+ code coverage achieved
- [ ] All tests passing
- [ ] No flaky tests
Common Testing Frameworks
JavaScript/TypeScript
- Jest, Vitest, Mocha + Chai
- Supertest (API testing)
- Playwright (E2E)
Python
- pytest, unittest
- requests-mock (API mocking)
- Selenium (E2E)
Go
- testing package
- testify (assertions)
- httptest (HTTP testing)
Java
- JUnit 5
- Mockito (mocking)
- RestAssured (API testing)
Related Resources
- Follow TDD workflow: RED → GREEN → REFACTOR
- Aim for 80%+ test coverage
- Keep tests fast and isolated
- Use descriptive test names
Security
- Security scanPassed, 90 of 100Pattern checks on the skill's files.
- Model reviewPassed
Quality evaluation
- Task evaluationNot runNo evaluation yet. Run one in Skill Studio.
Source
- SKILL.md in the repositoryCheckingassets/bundled_skills/test-helper/skill.md
Popularity
- 7-day trend score
- 0
Not refreshed yet.
Works with
Any agent vskill installs to: 56 targets in all. These 39 have a page on this site.
- Claude Code
- Cursor
- GitHub Copilot
- Windsurf
- Codex
- Gemini CLI
- Cline
- Amp
- Roo Code
- Goose
- Continue
- Kilo Code
- Junie
- Trae
- OpenHands
- Qwen Code
- AI Agent
- Tabnine Chat
- Sourcegraph Cody
- Amazon Q
- Firebase Genkit
- Sweep
- Devin
- Phind
- Mentat
- Claude Desktop
- Aider
- GPT Pilot
- Plandex
- bolt.new
- v0
- Replit Agent
- Anse
- TypingMind
- BetterChatGPT
- LibreChat
- Warp AI
- Pieces
- Fig AI
Embed badge
[](https://verified-skill.com/skills/2233admin/cicada/test-helper)