What problem does it solve?
Provide a clear, repeatable testing workflow for Django projects to reduce flaky tests, speed up development feedback, and ensure models, views, serializers, and REST APIs behave as intended.
Core Features & Use Cases
- Opinionated pytest configuration with reuse-db, no migrations, and coverage reporting to run fast test suites.
- Test settings and fixtures including in-memory SQLite, faster password hashing, timezone consistency, and reusable authenticated API clients.
- Factory-driven data using factory_boy for models, bulk creation, and realistic test data combined with DRF APIClient and Django test client examples.
- Mocking and integration patterns for external services, email, and payment flows to keep tests deterministic.
- Use Case: Implement and validate a new DRF product API using factories, authenticated API tests, and CI-friendly in-memory database runs.
Quick Start
Use the django-tdd workflow to run pytest with the included test settings, factories, and fixtures to validate your Django models and API endpoints.