making sure tests pass

This commit is contained in:
Burhan Khalid 2015-07-29 00:02:57 +03:00
parent a79e845533
commit 4b0d35194f

View File

@ -15,7 +15,6 @@ from __future__ import absolute_import, unicode_literals
from boto.s3.connection import OrdinaryCallingFormat from boto.s3.connection import OrdinaryCallingFormat
from django.utils import six from django.utils import six
{% if cookiecutter.use_sentry == "y" %} {% if cookiecutter.use_sentry == "y" %}
import raven
import logging import logging
{% endif %} {% endif %}
@ -24,7 +23,7 @@ from .common import * # noqa
# SECRET CONFIGURATION # SECRET CONFIGURATION
# ------------------------------------------------------------------------------ # ------------------------------------------------------------------------------
# See: https://docs.djangoproject.com/en/dev/ref/settings/#secret-key # See: https://docs.djangoproject.com/en/dev/ref/settings/#secret-key
# Raises ImproperlyConfigured exception if DJANO_SECRET_KEY not in os.environ # Raises ImproperlyConfigured exception if DJANGO_SECRET_KEY not in os.environ
SECRET_KEY = env("DJANGO_SECRET_KEY") SECRET_KEY = env("DJANGO_SECRET_KEY")
# This ensures that Django will be able to detect a secure connection # This ensures that Django will be able to detect a secure connection
@ -34,17 +33,14 @@ SECURE_PROXY_SSL_HEADER = ('HTTP_X_FORWARDED_PROTO', 'https')
# django-secure # django-secure
# ------------------------------------------------------------------------------ # ------------------------------------------------------------------------------
INSTALLED_APPS += ("djangosecure", ) INSTALLED_APPS += ("djangosecure", )
{% if cookiecutter.use_sentry == "y" -%}
{% if cookiecutter.use_sentry == "y" - %}
# raven sentry client # raven sentry client
# See https://docs.getsentry.com/hosted/clients/python/integrations/django/ # See https://docs.getsentry.com/hosted/clients/python/integrations/django/
INSTALLED_APPS += ('raven.contrib.django.raven_compat', ) INSTALLED_APPS += ('raven.contrib.django.raven_compat', )
{%- endif %} {%- endif %}
SECURITY_MIDDLEWARE = ( SECURITY_MIDDLEWARE = (
'djangosecure.middleware.SecurityMiddleware', 'djangosecure.middleware.SecurityMiddleware',
) )
{% if cookiecutter.use_sentry == "y" -%} {% if cookiecutter.use_sentry == "y" -%}
RAVEN_MIDDLEWARE = ('raven.contrib.django.raven_compat.middleware.Sentry404CatchMiddleware', RAVEN_MIDDLEWARE = ('raven.contrib.django.raven_compat.middleware.Sentry404CatchMiddleware',
'raven.contrib.django.raven_compat.middleware.SentryResponseErrorIdMiddleware',) 'raven.contrib.django.raven_compat.middleware.SentryResponseErrorIdMiddleware',)
@ -132,8 +128,7 @@ DEFAULT_FROM_EMAIL = env('DJANGO_DEFAULT_FROM_EMAIL',
EMAIL_BACKEND = 'django_mailgun.MailgunBackend' EMAIL_BACKEND = 'django_mailgun.MailgunBackend'
MAILGUN_ACCESS_KEY = env('DJANGO_MAILGUN_API_KEY') MAILGUN_ACCESS_KEY = env('DJANGO_MAILGUN_API_KEY')
MAILGUN_SERVER_NAME = env('DJANGO_MAILGUN_SERVER_NAME') MAILGUN_SERVER_NAME = env('DJANGO_MAILGUN_SERVER_NAME')
EMAIL_SUBJECT_PREFIX = env( EMAIL_SUBJECT_PREFIX = env("DJANGO_EMAIL_SUBJECT_PREFIX", default='[{{cookiecutter.project_name}}] ')
"DJANGO_EMAIL_SUBJECT_PREFIX", default='[{{cookiecutter.project_name}}] ')
SERVER_EMAIL = env('DJANGO_SERVER_EMAIL', default=DEFAULT_FROM_EMAIL) SERVER_EMAIL = env('DJANGO_SERVER_EMAIL', default=DEFAULT_FROM_EMAIL)
# TEMPLATE CONFIGURATION # TEMPLATE CONFIGURATION
@ -142,9 +137,7 @@ SERVER_EMAIL = env('DJANGO_SERVER_EMAIL', default=DEFAULT_FROM_EMAIL)
# https://docs.djangoproject.com/en/dev/ref/templates/api/#django.template.loaders.cached.Loader # https://docs.djangoproject.com/en/dev/ref/templates/api/#django.template.loaders.cached.Loader
TEMPLATES[0]['OPTIONS']['loaders'] = [ TEMPLATES[0]['OPTIONS']['loaders'] = [
('django.template.loaders.cached.Loader', [ ('django.template.loaders.cached.Loader', [
'django.template.loaders.filesystem.Loader', 'django.template.loaders.filesystem.Loader', 'django.template.loaders.app_directories.Loader', ]),
'django.template.loaders.app_directories.Loader',
]),
] ]
# DATABASE CONFIGURATION # DATABASE CONFIGURATION
@ -217,5 +210,4 @@ RAVEN_CONFIG = {
'CELERY_LOGLEVEL': env('DJANGO_SENTRY_LOG_LEVEL', logging.INFO) 'CELERY_LOGLEVEL': env('DJANGO_SENTRY_LOG_LEVEL', logging.INFO)
} }
{% endif %} {% endif %}
# Your production stuff: Below this line define 3rd party library settings # Your production stuff: Below this line define 3rd party library settings