Python Cheatsheet 07 — pytest Essentials
Cheatsheet: pytest basics, fixtures, parametrize, marks, conftest, pytest-asyncio.
Cheatsheet: pytest basics, fixtures, parametrize, marks, conftest, pytest-asyncio.
Cheatsheet: pytest setup, AsyncClient, real Postgres via testcontainers, factories, drift, migrations.
Cheatsheet: AsyncClient + pytest-anyio, dependency overrides, testcontainers Postgres, factory_boy, OpenAPI tests.
Testing FastAPI: TestClient and AsyncClient, dependency overrides, real DB testing with testcontainers, factory fixtures, and CI integration.
Testing SQLAlchemy: real DBs via testcontainers, per-test transactions, factory_boy, async fixtures, and CI patterns.
Cheatsheet: pytest-django, fixtures, model factories, API tests.
Cheatsheet: render, screen queries, user-event, async findBy, MSW.
Cheatsheet: vitest config, test, describe, mocks, snapshots, coverage.
Cheatsheet: unittest.mock, freezegun, snapshot, hypothesis, factory_boy.
Cheatsheet: parametrized tests, ValidationError assertions, factories, round-trip tests.