Reputation: 3253
My database has two types of entries: The very dynamic (users, comments, etc) and the more static (email templates, flat-pages).
During testing I want a clean DB but with the real 'semi-static' data.
Is there a way to make Django's testing system to load parts of the original DB ?
Thanks
Upvotes: 2
Views: 350
Reputation: 42208
Use fixtures. See the documentation or the (wiki page](https://code.djangoproject.com/wiki/Fixtures)
Put data you need into fixtures and they will be loaded every time test database is built.
Upvotes: 3