
Python Testing
Handles pytest fundamentals: fixtures, parametrization, coverage reporting, and mocking with unittest.mock. You'll reach for this when writing your first tests, setting up basic fixtures, or running TDD cycles on individual modules. The quick reference covers the commands you actually need (pytest -v, --cov, -k for filtering) and includes practical examples of parametrize decorators and fixture scopes. It's got a comparison table that's honest about when to graduate to pytest-advanced, which is refreshing. The conftest.py examples and pyproject.toml configuration will save you from hunting through docs. If you're building shared fixture libraries across multiple packages or tuning pytest-xdist for parallel execution, you've outgrown this one.
- skills.sh installs
- 463
- GitHub stars
- 59
- last updated
- Aug 21, 2026
Install
$ npx -y skills add laurigates/claude-plugins --skill python-testing --agent claude-codeInstalls into .claude/skills of the current project.
Files
Python Testing
Quick reference for Python testing with pytest, coverage, fixtures, and best practices.
When to Use This Skill
| Use this skill when... | Use pytest-advanced instead when... |
|---|---|
| Writing first pytest tests, learning fixtures and parametrization basics | Designing reusable conftest.py fixture hierarchies or parallel-execution markers |
Setting up coverage reporting and basic mocking with unittest.mock | Tuning pytest-xdist, custom markers, or hookimpl plugins |
| Following TDD red-green-refactor cycles on a single module | Building shared fixture libraries across a multi-package test suite |
When This Skill Applies
- Writing unit tests and integration tests
- Test-driven development (TDD)
- Test fixtures and parametrization
- Coverage analysis
- Mocking and patching
- Async testing
Quick Reference
Running Tests
# Basic test run
uv run pytest
# Verbose output
uv run pytest -v
# Show print statements
uv run pytest -s
# Stop at first failure
uv run pytest -x
# Run specific test
uv run pytest tests/test_module.py::test_function
# Run by keyword
uv run pytest -k "test_user"
Test Coverage
Sponsors
Details
- Repository
- github.com/laurigates/claude-plugins
- Categories
- Testing & QA, Documentation, Python
- First seen
- Jun 3, 2026