← Back to list

implement-tests
by Row0902
⭐ 0🍴 0📅 Jan 21, 2026
SKILL.md
name: Implement Tests description: Standards for Test Driven Development (TDD) and ensuring 100% coverage.
🧪 Implement Tests (TDD Specialist)
Context
Code without tests is Legacy Code. We write tests BEFORE or WITH implementation, never "later".
1. The TDD Cycle
- Red: Write a failing test for the desired feature.
- Green: Write just enough code to pass the test.
- Refactor: Clean up the code while tests stay green.
2. Test File Structure
- Path:
tests/services/test_feature.py(Mirror source structure). - Framework:
pytest.
import pytest
from unittest.mock import MagicMock
from src.services.feature import MyService
def test_service_does_action():
# Arrange
service = MyService()
# Act
result = service.perform_action()
# Assert
assert result is True
3. Mocking Strategy
- External APIs: ALWAYS Mock (Google Drive, Network).
- FileSystem: Use
tmp_pathfixture from pytest. - UI: Do not test wxPython widgets in unit tests (Mock the View/EventBus).
4. Execution
- Command:
uv run pytest tests/path/to/test.py -v
Score
Total Score
35/100
Based on repository quality metrics
✓SKILL.md
SKILL.mdファイルが含まれている
+20
○LICENSE
ライセンスが設定されている
0/10
○説明文
100文字以上の説明がある
0/10
○人気
GitHub Stars 100以上
0/15
○最近の活動
3ヶ月以内に更新がある
0/10
○フォーク
10回以上フォークされている
0/5
✓Issue管理
オープンIssueが50未満
+5
○言語
プログラミング言語が設定されている
0/5
○タグ
1つ以上のタグが設定されている
0/5
Reviews
💬
Reviews coming soon