top band

Wednesday 9 a.m.–12:20 p.m.

TDD with Django, from scratch: a beginner's intro to testing and web development

Harry Percival

Audience level:


A beginner's introduction to testing and web development with Django. We'll build a simple web app, from scratch, but with full TDD, including functional testing with Selenium and unit testing Django's views, templates, and models. Some familiarity with Python is desirable, but no prior knowledge of Django or testing is assumed.


The aim is to cover the basics of setting up a simple Django site, but using full, rigorous TDD at every step along the way. The tutorial is based on the first few chapters of my book, which is available (for free!) online for you to follow up with after the session, so that you can embed what you've learned. []( We'll learn: * how to set up functional tests with Selenium * how to set up Django * how to run Django unit tests * how TDD actually works in practice: the unit test / code cycle where we re-run the tests after each tiny, incremental change to the code * all the basics of Django like views, models and templates. We'll talk about what to test, what not to test, what the point of all this testing is anyway, you'll get a real hands-on feeling for how it works, and I promise to make it all at least moderately entertaining! And it's all in Python 3 :)

Student Handout

bottom band background