diff options
author | Étienne Loks <etienne.loks@iggdrasil.net> | 2017-04-18 14:58:49 +0200 |
---|---|---|
committer | Étienne Loks <etienne.loks@iggdrasil.net> | 2017-04-18 14:58:49 +0200 |
commit | c07c7fce2cecd4295894ca78085a473aaba5a13a (patch) | |
tree | fe298a148853ee08c4f3500cbdb268493dc688f0 | |
parent | 634a7ba8e09d2b5a177dc8bd71796512390218ef (diff) | |
download | Ishtar-c07c7fce2cecd4295894ca78085a473aaba5a13a.tar.bz2 Ishtar-c07c7fce2cecd4295894ca78085a473aaba5a13a.zip |
Django 1.8: new app management
-rw-r--r-- | ishtar_common/tests.py | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/ishtar_common/tests.py b/ishtar_common/tests.py index 133bd5a9b..49db86b64 100644 --- a/ishtar_common/tests.py +++ b/ishtar_common/tests.py @@ -156,8 +156,8 @@ class ManagedModelTestRunner(DiscoverRunner): to execute the SQL manually to create them. """ def setup_test_environment(self, *args, **kwargs): - from django.db.models.loading import get_models - self.unmanaged_models = [m for m in get_models() + from django.apps import apps + self.unmanaged_models = [m for m in apps.get_models() if not m._meta.managed] for m in self.unmanaged_models: m._meta.managed = True |