testing-python
Stratégie de Tests Python 3.14+. Use when writing tests, reviewing test coverage, or setting up testing.
How do I install this agent skill?
npx skills add https://github.com/thebeardedbearsas/claude-craft --skill testing-pythonIs this agent skill safe to install?
- Gen Agent Trust Hubpass
This skill is a documentation reference for Python testing strategies and contains no executable code, network operations, or risky patterns.
- Socketpass
No alerts
- Snykpass
Risk: LOW · No issues
- Runlayerpass
1 file scanned · No issues
- ZeroLeakspass
Score: 93/100 · 2 sections analyzed
What does this agent skill do?
Stratégie de Tests Python 3.14+
Versions : Python 3.14+ | pytest 8.x | Ruff 0.8+ | mypy 1.13+ | Playwright
Ruff remplace Black + isort + Flake8 (10-100x plus rapide). mypy strict élimine les bugs de type à la compilation.
Stack recommandée 2026
| Type | Outil | Usage |
|---|---|---|
| Unit/Integration | pytest 8.x | Tests backend FastAPI/Django |
| Linting + Format | Ruff 0.8+ | 10-100× plus rapide que Black+Flake8 |
| Type checking | mypy 1.13+ strict | Vérification statique |
| E2E/Browser | Playwright | Tests frontend web |
| Mutation | Mutmut | Qualité des tests (score >= 80%) |
| Property-based | Hypothesis | Génération de cas de test automatique |
Sources : pytest, Ruff, Mutmut
Invariants non-négociables
- Couverture >= 80% (
--cov-fail-under=80danspyproject.toml) - mypy strict — zéro
Anynon justifié,disallow_untyped_defs = true - Ruff obligatoire (check + format) dans CI
- Pattern AAA (Arrange-Act-Assert) dans chaque test
- Fixtures pytest pour l'injection de dépendances (pas d'état global)
- Mutation score >= 80% via Mutmut
Checklist par type
| Type | Vérification |
|---|---|
| Unit | Isolation totale, fixtures pytest, mocks unittest.mock |
| Integration | TestClient FastAPI / Client Django, DB de test |
| E2E | Playwright sync_api, expect() assertions |
| Property | Hypothesis @given pour edge cases automatiques |
| Mutation | mutmut run, score >= 80 avant merge |
Détails complets, exemples de code, configs et checklists : voir REFERENCE.md
How can the creator link this skill?
Add the canonical catalog link to the repository README so users can inspect current installs and available audits. The publishing guide covers the complete discovery path.
<a href="https://skillzs.dev/skills/thebeardedbearsas/claude-craft/testing-python">View testing-python on skillZs</a>