]> git.ozlabs.org Git - patchwork/blobdiff - patchwork/settings/dev.py
Move to a more recent django project structure
[patchwork] / patchwork / settings / dev.py
diff --git a/patchwork/settings/dev.py b/patchwork/settings/dev.py
new file mode 100644 (file)
index 0000000..6e373cc
--- /dev/null
@@ -0,0 +1,52 @@
+"""
+Development settings for patchwork project.
+
+These are also used in unit tests.
+
+Design based on:
+    http://www.revsys.com/blog/2014/nov/21/recommended-django-project-layout/
+"""
+
+import django
+
+from base import *
+
+#
+# Core settings
+# https://docs.djangoproject.com/en/1.6/ref/settings/#core-settings
+#
+
+# Security
+
+SECRET_KEY = '00000000000000000000000000000000000000000000000000'
+
+# Debugging
+
+DEBUG = True
+
+# Templates
+
+TEMPLATE_DEBUG = True
+
+# Database
+
+DATABASES = {
+    'default': {
+        'ENGINE': 'django.db.backends.mysql',
+        'HOST': 'localhost',
+        'PORT': '',
+        'USER': os.environ['PW_TEST_DB_USER'],
+        'PASSWORD': os.environ['PW_TEST_DB_PASS'],
+        'NAME': 'patchwork',
+        'TEST_CHARSET': 'utf8',
+    },
+}
+
+if django.VERSION >= (1, 7):
+    TEST_RUNNER = 'django.test.runner.DiscoverRunner'
+
+#
+# Patchwork settings
+#
+
+ENABLE_XMLRPC = True