From b2c9ba63465a88a3fb7297d49c371a0cff9bcd82 Mon Sep 17 00:00:00 2001 From: Bertrand Bordage Date: Tue, 21 Oct 2014 20:42:40 +0200 Subject: [PATCH] Only add South in Django < 1.7. --- runtests.py | 15 +++++++++------ 1 file changed, 9 insertions(+), 6 deletions(-) diff --git a/runtests.py b/runtests.py index b751a4d..f953038 100755 --- a/runtests.py +++ b/runtests.py @@ -47,13 +47,16 @@ DEFAULT_CACHE_KEY = os.environ.get('CACHE_BACKEND', 'locmem') CACHES['default'] = CACHES[DEFAULT_CACHE_KEY] del CACHES[DEFAULT_CACHE_KEY] +INSTALLED_APPS = [ + 'cachalot', + 'django.contrib.auth', + 'django.contrib.contenttypes', +] +if django.VERSION < (1, 7): + INSTALLED_APPS.append('south') + settings.configure( - INSTALLED_APPS=( - 'cachalot', - 'django.contrib.auth', - 'django.contrib.contenttypes', - 'south', - ), + INSTALLED_APPS=INSTALLED_APPS, DATABASES=DATABASES, CACHES=CACHES, MIDDLEWARE_CLASSES=(),