django-forms-validation-tdd

Installation
SKILL.md

Django Forms Validation TDD

Use this skill to place validation tests at the layer that owns the rule, then prove the user-facing error path still works. Django validation often crosses model, form, view, and template boundaries; keep those responsibilities explicit.

Source Traceability

Primary source: Harry Percival, Test-Driven Development with Python, 3rd ed. Guidance is transformed and paraphrased from chapters 14-16 and Appendix A, especially model constraints, form validation, ModelForm tradeoffs, view-level error surfacing, and duplicate item handling.

Workflow

  1. Classify the validation rule.
    • Data integrity belongs near the model or database constraint.
    • User input shape and presentation belong in a form.
    • Request branching and redirects belong in the view.
    • Error rendering belongs in the template.
Installs
2
Repository
lvtd-llc/skills
GitHub Stars
1
First Seen
Jul 12, 2026
django-forms-validation-tdd — lvtd-llc/skills