Monday¶
Objectives¶
- Understand how to implement a data model in Django.
- Understand what a database migration is and how migrations control the relationship between the database and the app.
- Learn about the Binary Search Tree and how it is structured.
- Be able to reliably test a Django app.
Readings¶
- Walk through how to add and insert nodes to a binary search tree at VisuAlgo
- Code School’s Try Django Tutorial
- Writing and Running Tests in Django
- Testing in Django
- Django Testing Tools
- Testing Scenarios for Django
- Django Girls Tutorial
These readings will support your work on the Data Model for our Django Imager website.
- Django Models API
- Django Model Managers
- Django’s Signal Framework, Built-In Signals and Signal Handling (You’ll also want to read up on using the new App Config system to register signals and signal handlers)
- Django Testing (familiarize yourself both with writing and running tests and with the tools Django provides for testing.
- Using Dynamic Test Fixtures with Factory Boy (in particular pay attention to using Factory Boy with Django)
- Django Migrations
Review¶
Demo¶
- Writing first tests with Django