This repository has been archived by the owner on Feb 1, 2019. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 11
/
test_settings.py
executable file
·98 lines (90 loc) · 2.79 KB
/
test_settings.py
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
#!/usr/bin/env python
# -*- coding: utf-8 -*-
from __future__ import unicode_literals
gettext = lambda s: s # flake8: noqa
HELPER_SETTINGS = {
'CMS_PERMISSION': True,
'TIME_ZONE': 'Europe/Zurich',
'INSTALLED_APPS': [
'absolute',
'aldryn_apphooks_config',
# needed for tests, since we need to reload server after apphook has
# been added to a page, otherwise we cannot get a correct url.
'aldryn_apphook_reload',
'aldryn_categories',
'aldryn_translation_tools',
'aldryn_common',
'bootstrap3',
'appconf',
'filer',
'parler',
'sortedm2m',
'easy_thumbnails',
'djangocms_text_ckeditor',
'emailit',
'adminsortable2',
'standard_form',
],
'THUMBNAIL_PROCESSORS': (
'easy_thumbnails.processors.colorspace',
'easy_thumbnails.processors.autocrop',
'filer.thumbnail_processors.scale_and_crop_with_subject_location',
'easy_thumbnails.processors.filters',
),
'LANGUAGES': (
('en', 'English'),
('de', 'German'),
),
'PARLER_LANGUAGES': {
1: (
{'code': 'en'},
{'code': 'de'},
),
'default': {
'hide_untranslated': False,
}
},
'CMS_LANGUAGES': {
'default': {
'public': True,
'hide_untranslated': False,
'fallbacks': ['en']
},
1: [
{
'public': True,
'code': 'en',
'hide_untranslated': False,
'name': gettext('en'),
'redirect_on_fallback': True,
},
{
'public': True,
'code': 'de',
'hide_untranslated': False,
'name': gettext('de'),
'redirect_on_fallback': True,
},
],
},
'MIDDLEWARE_CLASSES': [
'django.middleware.http.ConditionalGetMiddleware',
'django.contrib.sessions.middleware.SessionMiddleware',
'django.contrib.auth.middleware.AuthenticationMiddleware',
'django.contrib.messages.middleware.MessageMiddleware',
'django.middleware.csrf.CsrfViewMiddleware',
'django.middleware.locale.LocaleMiddleware',
'django.middleware.common.CommonMiddleware',
'cms.middleware.utils.ApphookReloadMiddleware',
'cms.middleware.language.LanguageCookieMiddleware',
'cms.middleware.user.CurrentUserMiddleware',
'cms.middleware.page.CurrentPageMiddleware',
'cms.middleware.toolbar.ToolbarMiddleware'
],
'EMAIL_BACKEND': 'django.core.mail.backends.console.EmailBackend',
}
def run():
from djangocms_helper import runner
runner.cms('aldryn_jobs')
if __name__ == "__main__":
run()