Part III. Forms and Validation
Now that we’ve got things into production, we’ll spend a bit of time on validation, a core topic in web development.
There’s quite a lot of Django-specific content in this part, so if you weren’t familiar with Django before starting on the book, you may find that taking a little time to run through the official Django tutorial will complement the next few chapters nicely.
With that said, there are lots of good lessons about test-driven development (TDD) in general in here too! So, alternatively, if you’re not that interested in Django itself, don’t worry too much about the details; instead, look out for the more general principles of testing.
Here’s a little preview of what we’ll cover:
-
Splitting tests out across multiple files
-
Using a decorator for Selenium waits/polling
-
Database-layer validation and constraints
-
HTML5 form validation in the frontend
-
The Django forms framework
-
The trade-offs of frameworks in general, and when to stop using them
-
How far to go when testing for possible coding errors
-
An overview of all the typical tests for Django views
Become an O’Reilly member and get unlimited access to this title plus top books and audiobooks from O’Reilly and nearly 200 top publishers, thousands of courses curated by job role, 150+ live events each month,
and much more.
Read now
Unlock full access