Django: Getting Started Transcripts
Chapter: Django ORM and Databases
Lecture: Running all tests

Login or purchase this course to watch this video and the rest of the course contents.
0:00 Now I'll run all of the tests in catalog test case. And let's look at the difference, below the first set of equal signs.
0:11 You'll see setup got called and then test listing. Then below the second set of equal signs. You'll see setup got called again.
0:19 Note that it starts out with no books and no authors. Django has rolled the database back to the initial state before running the 2nd test.
0:30 This is a good thing. It means that if one of the tests changes the database, it won't impact the other tests. You don't have to worry about the order.
0:39 The tests are run in, both test listing and test stringify got run successfully and then Django helpfully destroys the test database for you.


Talk Python's Mastodon Michael Kennedy's Mastodon