forked from squadrun/django-sql-explorer
-
Notifications
You must be signed in to change notification settings - Fork 0
/
test_settings.py
101 lines (86 loc) · 2.36 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
99
100
101
import os
# import djcelery
SECRET_KEY = 'shhh'
DEBUG = True
STATIC_URL = '/static/'
ALLOWED_HOSTS = ['0.0.0.0', 'localhost', '127.0.0.1']
BASE_DIR = os.path.dirname(os.path.dirname(__file__))
DATABASES = {
'default': {
'ENGINE': 'django.db.backends.sqlite3',
'NAME': 'tmp',
'TEST': {
'NAME': 'test_tmp'
}
},
'alt': {
'ENGINE': 'django.db.backends.sqlite3',
'NAME': 'tmp2',
'TEST': {
'NAME': 'test_tmp2'
}
},
'not_registered': {
'ENGINE': 'django.db.backends.sqlite3',
'NAME': 'tmp3',
'TEST': {
'NAME': 'test_tmp3'
}
}
}
EXPLORER_CONNECTIONS = {
#'Postgres': 'postgres',
#'MySQL': 'mysql',
'SQLite': 'default',
'Another': 'alt'
}
EXPLORER_DEFAULT_CONNECTION = 'default'
ROOT_URLCONF = 'explorer.tests.urls'
TEMPLATES = [
{
'BACKEND': 'django.template.backends.django.DjangoTemplates',
'DIRS': [],
'APP_DIRS': True,
'OPTIONS': {
'context_processors': [
'django.contrib.auth.context_processors.auth',
'django.contrib.messages.context_processors.messages',
'django.template.context_processors.static',
'django.template.context_processors.request',
],
'debug': DEBUG
},
},
]
INSTALLED_APPS = (
'django.contrib.auth',
'django.contrib.contenttypes',
'django.contrib.sessions',
'django.contrib.messages',
'django.contrib.staticfiles',
'django.contrib.admin',
'explorer',
# 'djcelery'
)
AUTHENTICATION_BACKENDS = (
"django.contrib.auth.backends.ModelBackend",
)
MIDDLEWARE_CLASSES = [
'django.contrib.sessions.middleware.SessionMiddleware',
'django.middleware.common.CommonMiddleware',
'django.middleware.csrf.CsrfViewMiddleware',
'django.contrib.auth.middleware.AuthenticationMiddleware',
'django.contrib.messages.middleware.MessageMiddleware',
]
# TEST_RUNNER = 'djcelery.contrib.test_runner.CeleryTestSuiteRunner'
# djcelery.setup_loader()
CELERY_ALWAYS_EAGER = True
BROKER_BACKEND = 'memory'
# Explorer-specific
EXPLORER_TRANSFORMS = (
('foo', '<a href="{0}">{0}</a>'),
('bar', 'x: {0}')
)
EXPLORER_USER_QUERY_VIEWS = {}
EXPLORER_TASKS_ENABLED = True
EXPLORER_S3_BUCKET = 'thisismybucket.therearemanylikeit.butthisoneismine'