As a Django Developer, I like to use
CI to help me improve the quality of my software.
But as the Django project grow bigger and bigger, I find the tests become slow, the test code and test data are not easy to maintain.
So I need some great resources which can tell me some
best-practices about Django tests.
Speed Up Your Django Tests is the Book which can help solve the above problems!
Who is the author
The Book is written by
Adam Johnson, who is a very experienced Django developer. He is also a member of the Django project Technical Board.
Who is the Book for
If you already have a basic understanding of Python, Django, and the tests are already running in your Django project, then this Book is for you.
Here I want to list some highlights of the Book (just in my opinion)
How to measure your Django tests.
11 Tips to speed your Django tests in 5 mins.
How to do parallel testing.
Why it is not a good idea to disable Migrations in Tests (even it can speed up your tests)
How to config CI to reduce your CI test run time.
Why you should avoid using fixture files
How to use Mocking in your tests
How I read the Book
After I received the release email (I pre-order the Book some weeks ago), I downloaded the Book, and the sample project source code from Gumroad.
Then I took several hours to read the Book, and pick one of my projects to import solutions from the Book into.
I wrote notes during the process because I can check them in the future.
I also sent an email to Adam to ask some questions and got a quick response, which is incredible!
Fast tests can let us find problems in less time and they can really benefit our development.
If you are also struggling to speed your Django tests, then I highly recommend this Book.
The current price is $49, supporting a refund within 30 days.
Here is the book link and hope you enjoy it! Speed Up Your Django Tests