aboutsummaryrefslogtreecommitdiffstats
path: root/runtests.py
diff options
context:
space:
mode:
authorJannis Leidel2013-03-02 14:09:30 +0100
committerJannis Leidel2013-03-02 14:09:30 +0100
commit0844c8b24527486d43f8ab18241ce0b7f900129b (patch)
treed9db1cd777ee7b122665b5358c0b1d24d30f93a7 /runtests.py
parent42d7dde77e1c2daffaa5fa5bd16184f52c413c20 (diff)
parent54f4f3a7361ae711641b511df5a4c8962ad623a4 (diff)
downloaddjango-debug-toolbar-0844c8b24527486d43f8ab18241ce0b7f900129b.tar.bz2
Merge branch 'issue_230' of git://github.com/akaariai/django-debug-toolbar into akaariai-issue_230
Conflicts: debug_toolbar/utils/tracking/db.py
Diffstat (limited to 'runtests.py')
-rw-r--r--runtests.py5
1 files changed, 4 insertions, 1 deletions
diff --git a/runtests.py b/runtests.py
index 3432f8b..ed49824 100644
--- a/runtests.py
+++ b/runtests.py
@@ -1,11 +1,14 @@
#!/usr/bin/env python
import sys
+import os
from os.path import dirname, abspath
from optparse import OptionParser
from django.conf import settings, global_settings
-if not settings.configured:
+# For convenience configure settings if they are not pre-configured or if we
+# haven't been provided settings to use by environment variable.
+if not settings.configured and not os.environ.get('DJANGO_SETTINGS_MODULE'):
settings.configure(
DATABASES={
'default': {