开发与测试
testing
Write comprehensive tests
AgriciDaniel · 已有静态检查记录
安装与使用
运行命令前先阅读来源与依赖说明。复制命令不会自动安装或执行。
npx skills add AgriciDaniel/claude-code-essentials-vs-code --skill testing技能说明
name: testing description: Write comprehensive tests
When writing tests:
- Use descriptive names: "should [behavior] when [condition]"
- Follow Arrange-Act-Assert (AAA) pattern
- Test edge cases: null, empty, boundary values
- Mock external dependencies appropriately
- Prefer integration tests for critical paths
- Aim for 80% coverage minimum
- Use test fixtures for complex data setup
- Test error scenarios and edge cases
- Keep tests independent and isolated
- Use parameterized tests for similar scenarios