I have an app in Django 1.7.4 that I would like to use purely for testing.

    $ ./manage.py startapp override

The app contains its own model, view, and URL pattern (the model overrides a 
model in another app, allowing me to test behavior in a specific case).

For the moment, I have the app in INSTALLED_APPS, and the tests run fine. 
However, I would like to remove the app from INSTALLED_APPS, and override the 
setting just for the tests. In theory:

    @modify_settings(INSTALLED_APPS={'append': 'override'})

However, if I then remove the string from project_name/settings.py, I am given 
a Python Traceback which ends in:

    django.db.utils.OperationalError: no such table: override_modelname

How may I force the TestCase class to apply the migration file 
override/migrations/0001_initial.py to the test database? 

Thanks,
Andrew

-- 
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 django-users+unsubscr...@googlegroups.com.
To post to this group, send email to django-users@googlegroups.com.
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/3A0C68F2-C408-4ECA-B2B3-CD309C680C10%40andrewsforge.com.
For more options, visit https://groups.google.com/d/optout.

Reply via email to