Browse Source

Move app stub para pacote específico

pull/255/head
Marcio Mazza 9 years ago
parent
commit
ae7dbae0c1
  1. 9
      crud/tests/settings.py
  2. 0
      crud/tests/stub_app/layouts.yaml
  3. 0
      crud/tests/stub_app/models.py
  4. 0
      crud/tests/stub_app/templates/base.html
  5. 0
      crud/tests/stub_app/urls.py
  6. 0
      crud/tests/stub_app/views.py
  7. 4
      crud/tests/test_base.py

9
crud/tests/settings.py

@ -5,8 +5,7 @@ BASE_DIR = dirname(dirname(dirname(__file__)))
DATABASES = { DATABASES = {
'default': { 'default': {
'ENGINE': 'django.db.backends.sqlite3', 'ENGINE': 'django.db.backends.sqlite3',
# 'NAME': ':memory:', 'NAME': ':memory:',
'NAME': '/tmp/db',
}, },
} }
@ -15,11 +14,11 @@ INSTALLED_APPS = (
'django.contrib.auth', 'django.contrib.auth',
'django.contrib.messages', 'django.contrib.messages',
'django.contrib.sessions', 'django.contrib.sessions',
'crud.tests', 'crud.tests.stub_app',
'crispy_forms', 'crispy_forms',
) )
ROOT_URLCONF = 'crud.tests.urls' ROOT_URLCONF = 'crud.tests.stub_app.urls'
USE_TZ = True USE_TZ = True
@ -27,7 +26,7 @@ SECRET_KEY = 'zzz...'
TEMPLATES = [{ TEMPLATES = [{
'BACKEND': 'django.template.backends.django.DjangoTemplates', 'BACKEND': 'django.template.backends.django.DjangoTemplates',
'DIRS': [join(BASE_DIR, 'crud/tests/templates'), 'DIRS': [join(BASE_DIR, 'crud/tests/stub_app/templates'),
join(BASE_DIR, 'templates')], join(BASE_DIR, 'templates')],
'APP_DIRS': True, 'APP_DIRS': True,
'OPTIONS': { 'OPTIONS': {

0
crud/tests/layouts.yaml → crud/tests/stub_app/layouts.yaml

0
crud/tests/models.py → crud/tests/stub_app/models.py

0
crud/tests/templates/base.html → crud/tests/stub_app/templates/base.html

0
crud/tests/urls.py → crud/tests/stub_app/urls.py

0
crud/tests/views.py → crud/tests/stub_app/views.py

4
crud/tests/test_base.py

@ -5,8 +5,8 @@ from model_mommy import mommy
from crud.base import (CrispyLayoutFormMixin, CrudListMixin, from_to, from crud.base import (CrispyLayoutFormMixin, CrudListMixin, from_to,
get_field_display, make_pagination) get_field_display, make_pagination)
from .models import Continent, Country from .stub_app.models import Continent, Country
from .views import CountryCrudListMixin from .stub_app.views import CountryCrudListMixin
pytestmark = pytest.mark.django_db pytestmark = pytest.mark.django_db

Loading…
Cancel
Save