> Den 12/06/2015 kl. 11.38 skrev Cherie Pun <[email protected] > <mailto:[email protected]>>: > > Hi, > > I have trying to experiment with squashmigration to see if it will make it > faster to build the database when running tests. So I have squashed the > migrations following the instructions on the Django website. However when I > run the tests, it still uses the original migrations. I thought Django > automatically uses the squashed one over the separated ones. Is there some > settings that I have to configure? Also, it says that no optimisation was > available even though there are a few AddField which should in theory be > combined into AddModel.
squashmigrations has limits to what it can do. You are free to edit the migration by hand if you can spot any more optimizations, and file a bug report if you spot something that the squasher should reasonably detect. Have you seen the new "manage.py test --keepdb" in Django 1.8? I have a complicated project with lots of apps and use it daily to speed up testing. https://docs.djangoproject.com/en/1.8/ref/django-admin/#test-app-or-test-identifier <https://docs.djangoproject.com/en/1.8/ref/django-admin/#test-app-or-test-identifier> Erik -- You received this message because you are subscribed to the Google Groups "Django users" group. To unsubscribe from this group and stop receiving emails from it, send an email to [email protected]. To post to this group, send email to [email protected]. Visit this group at http://groups.google.com/group/django-users. To view this discussion on the web visit https://groups.google.com/d/msgid/django-users/5968C3C9-1515-4B61-9E9C-964EC60B030E%40cederstrand.dk. For more options, visit https://groups.google.com/d/optout.

