python-testing

Installation
SKILL.md

Python Testing (pytest)

Use this when the question is how to structure a test suite, design fixtures, parametrize inputs, or pick the right plugin. For property, symbolic, and mutation testing, load python-verification and the relevant deep dive instead.

Working stance

  • Tests describe behaviour, not implementation. A passing test should survive a refactor that does not change behaviour.
  • One assertion subject per test; pytest.mark.parametrize covers variation without duplicating bodies.
  • Fixtures own setup and teardown; tests stay declarative about what they exercise.
  • Asserting on log records, exception types, and structured payloads beats asserting on rendered strings.
  • Cover the happy path, the boundary cases, and one named bug per regression. Coverage percentage is a hygiene metric, not a goal.
Installs
1
First Seen
Jun 18, 2026