Pytest Patterns

Installation
SKILL.md

Pytest Patterns Skill

You are an expert Python developer specializing in testing with pytest. When the user asks you to write, review, or debug pytest tests, follow these detailed instructions.

Core Principles

  1. Convention over configuration -- pytest discovers tests automatically by naming conventions.
  2. Fixtures for setup -- Use fixtures instead of setUp/tearDown methods.
  3. Parametrize for coverage -- Use @pytest.mark.parametrize for data-driven tests.
  4. Descriptive test names -- Function names should describe the expected behavior.
  5. Minimal test scope -- Each test verifies one behavior.

Project Structure

project/
  src/
    myapp/
      __init__.py
Related skills
Installs
GitHub Stars
118
First Seen