pytest
Installation
SKILL.md
Skill: pytest
Best practices for writing and organizing tests with pytest including fixtures, parametrize, and plugins.
When to Use
Apply this skill when writing and organizing tests with pytest — fixtures, parametrize, markers, plugins, and test structure.
Test Organization
- Place tests in a
tests/directory mirroring the source structure. - Name test files
test_<module>.pyand test functionstest_<behavior>(). - Group related tests in classes only when they share fixtures/setup.