passing tests
This commit is contained in:
BIN
rowers/tests/testdata/testdata.csv.gz
vendored
BIN
rowers/tests/testdata/testdata.csv.gz
vendored
Binary file not shown.
@@ -518,6 +518,7 @@ urlpatterns = [
|
|||||||
re_path(r'^checkout/(?P<planid>\d+)/$',views.payment_confirm_view,name='payment_confirm_view'),
|
re_path(r'^checkout/(?P<planid>\d+)/$',views.payment_confirm_view,name='payment_confirm_view'),
|
||||||
re_path(r'^upgradecheckout/(?P<planid>\d+)/$',views.upgrade_confirm_view,name='upgrade_confirm_view'),
|
re_path(r'^upgradecheckout/(?P<planid>\d+)/$',views.upgrade_confirm_view,name='upgrade_confirm_view'),
|
||||||
re_path(r'^upgradecheckout/(?P<planid>\d+)/$',views.upgrade_confirm_view,name='upgrade_confirm_view'),
|
re_path(r'^upgradecheckout/(?P<planid>\d+)/$',views.upgrade_confirm_view,name='upgrade_confirm_view'),
|
||||||
|
re_path(r'^downgradecheckout/(?P<planid>\d+)/$',views.downgrade_confirm_view,name='downgrade_confirm_view'),
|
||||||
re_path(r'^billing/$',views.billing_view,name='billing'),
|
re_path(r'^billing/$',views.billing_view,name='billing'),
|
||||||
re_path(r'^upgrade/$',views.upgrade_view,name='upgrade'),
|
re_path(r'^upgrade/$',views.upgrade_view,name='upgrade'),
|
||||||
re_path(r'^downgrade/$',views.downgrade_view,name='downgrade'),
|
re_path(r'^downgrade/$',views.downgrade_view,name='downgrade'),
|
||||||
|
|||||||
@@ -166,7 +166,9 @@ DATABASES = {
|
|||||||
},
|
},
|
||||||
'TEST': {
|
'TEST': {
|
||||||
'CHARSET': 'utf8',
|
'CHARSET': 'utf8',
|
||||||
|
'ENGINE': 'django.db.backends.mysql',
|
||||||
'COLLATION': 'utf8_general_ci',
|
'COLLATION': 'utf8_general_ci',
|
||||||
|
'NAME': CFG['db_name']
|
||||||
},
|
},
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -10,34 +10,40 @@ For the full list of settings and their values, see
|
|||||||
https://docs.djangoproject.com/en/1.9/ref/settings/
|
https://docs.djangoproject.com/en/1.9/ref/settings/
|
||||||
"""
|
"""
|
||||||
from .settings import *
|
from .settings import *
|
||||||
|
import sys
|
||||||
|
|
||||||
try:
|
try:
|
||||||
use_sqlite = CFG['use_sqlite']
|
use_sqlite = CFG['use_sqlite']
|
||||||
except KeyError:
|
except KeyError:
|
||||||
use_sqlite = False
|
use_sqlite = False
|
||||||
|
|
||||||
if use_sqlite:
|
if 'test' in sys.argv:
|
||||||
|
TESTING = True
|
||||||
|
|
||||||
|
|
||||||
|
if TESTING:
|
||||||
DATABASES = {
|
DATABASES = {
|
||||||
'default': {
|
'default': {
|
||||||
'ENGINE': 'django.db.backends.sqlite3',
|
'ENGINE': 'django.db.backends.sqlite3',
|
||||||
'NAME': os.path.join(BASE_DIR, 'db.sqlite3'),
|
'NAME': os.path.join(BASE_DIR, 'db.sqlite3'),
|
||||||
'HOST': 'localhost',
|
'HOST': 'localhost',
|
||||||
},
|
},
|
||||||
# 'TEST': {
|
# 'TEST': {
|
||||||
# 'CHARSET': 'utf8',
|
# 'CHARSET': 'utf8',
|
||||||
# 'COLLATION': 'utf8_general_ci',
|
# 'COLLATION': 'utf8_general_ci',
|
||||||
# },
|
# },
|
||||||
|
|
||||||
# 'slave': {
|
# 'slave': {
|
||||||
# 'ENGINE': 'django.db.backends.mysql',
|
# 'ENGINE': 'django.db.backends.mysql',
|
||||||
# 'NAME': 'rowsanda_107501',
|
# 'NAME': 'rowsanda_107501',
|
||||||
# 'USER': 'rowsanda_107501',
|
# 'USER': 'rowsanda_107501',
|
||||||
# 'PASSWORD': 'roeidata',
|
# 'PASSWORD': 'roeidata',
|
||||||
# 'HOST': 'store3.rosti.cz',
|
# 'HOST': 'store3.rosti.cz',
|
||||||
# 'PORT': '3306',
|
# 'PORT': '3306',
|
||||||
# }
|
# }
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
BROKER_URL = 'redis://localhost:6379/0'
|
BROKER_URL = 'redis://localhost:6379/0'
|
||||||
CELERY_RESULT_BACKEND = 'redis://localhost:6379/0'
|
CELERY_RESULT_BACKEND = 'redis://localhost:6379/0'
|
||||||
CELERY_IGNORE_RESULT = False
|
CELERY_IGNORE_RESULT = False
|
||||||
@@ -64,7 +70,7 @@ ALLOWED_HOSTS = ['localhost']
|
|||||||
CACHES = {
|
CACHES = {
|
||||||
'default': {
|
'default': {
|
||||||
'BACKEND': 'django.core.cache.backends.filebased.FileBasedCache',
|
'BACKEND': 'django.core.cache.backends.filebased.FileBasedCache',
|
||||||
'LOCATION': 'C:/python/rowsandallapp/django_cache',
|
'LOCATION': os.path.join(BASE_DIR, 'django_cache'),
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
9
rowsandall_app/settings_test.py
Normal file
9
rowsandall_app/settings_test.py
Normal file
@@ -0,0 +1,9 @@
|
|||||||
|
from .settings_dev import *
|
||||||
|
|
||||||
|
DATABASES = {
|
||||||
|
'default': {
|
||||||
|
'ENGINE': 'django.db.backends.sqlite3',
|
||||||
|
'NAME': os.path.join(BASE_DIR, 'db.sqlite3'),
|
||||||
|
'HOST': 'localhost',
|
||||||
|
},
|
||||||
|
}
|
||||||
Reference in New Issue
Block a user