← スキル一覧に戻る

testing-standards
by michelabboud
⭐ 2🍴 0📅 2026年1月16日
SKILL.md
name: testing-standards description: Write comprehensive tests following TDD and best practices. Use when generating unit tests, integration tests, or end-to-end tests for any code dependencies:
- jest
- @testing-library/react
Testing Standards Skill
Test Structure (AAA Pattern)
describe('Component/Function Name', () => {
it('should do something specific', () => {
// Arrange - Set up test data
const input = { foo: 'bar' }
// Act - Execute the code
const result = functionUnderTest(input)
// Assert - Verify results
expect(result).toEqual(expectedOutput)
})
})
Test Categories
Unit Tests
- Test single functions/methods
- Mock all dependencies
- Fast (<100ms per test)
- High coverage (80%+)
Integration Tests
- Test component interactions
- Use test database
- Moderate speed
- Focus on critical paths
E2E Tests
- Test complete user flows
- Use real browser
- Slower execution
- Test happy paths only
Best Practices
- Descriptive Names:
it('should return 401 when token is expired') - One Assert Per Concept: Test one thing at a time
- Independent Tests: No shared state between tests
- Use Factories: Create test data with factories
- Mock External Services: APIs, databases, file system
スコア
総合スコア
60/100
リポジトリの品質指標に基づく評価
✓SKILL.md
SKILL.mdファイルが含まれている
+20
✓LICENSE
ライセンスが設定されている
+10
○説明文
100文字以上の説明がある
0/10
○人気
GitHub Stars 100以上
0/15
○最近の活動
3ヶ月以内に更新がある
0/10
○フォーク
10回以上フォークされている
0/5
✓Issue管理
オープンIssueが50未満
+5
✓言語
プログラミング言語が設定されている
+5
○タグ
1つ以上のタグが設定されている
0/5
レビュー
💬
レビュー機能は近日公開予定です