forked from django-cms/django-sekizai
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Turned runtest.sh+buildout+magic into runtests.py+awesomeness
- Loading branch information
Jonas Obrist
committed
Oct 22, 2011
1 parent
3de7d6f
commit 4332963
Showing
41 changed files
with
56 additions
and
310 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,56 @@ | ||
# -*- coding: utf-8 -*- | ||
import os | ||
import sys | ||
|
||
urlpatterns = [] | ||
|
||
TEMPLATE_DEBUG = True | ||
|
||
DATABASES = { | ||
'default': { | ||
'ENGINE': 'sqlite3', | ||
'NAME': ':memory:' | ||
} | ||
} | ||
|
||
|
||
INSTALLED_APPS = [ | ||
'sekizai', | ||
] | ||
|
||
TEMPLATE_DIRS = [ | ||
os.path.join(os.path.dirname(__file__), 'test_templates'), | ||
] | ||
|
||
TEMPLATE_CONTEXT_PROCESSORS = [ | ||
'sekizai.context_processors.sekizai', | ||
] | ||
|
||
|
||
ROOT_URLCONF = 'runtests' | ||
|
||
def run_tests(): | ||
from django.conf import settings | ||
settings.configure( | ||
INSTALLED_APPS = INSTALLED_APPS, | ||
ROOT_URLCONF = ROOT_URLCONF, | ||
DATABASES = DATABASES, | ||
TEST_RUNNER = 'django.test.simple.DjangoTestSuiteRunner', | ||
TEMPLATE_DIRS = TEMPLATE_DIRS, | ||
TEMPLATE_CONTEXT_PROCESSORS = TEMPLATE_CONTEXT_PROCESSORS, | ||
TEMPLATE_DEBUG = TEMPLATE_DEBUG | ||
) | ||
|
||
# Run the test suite, including the extra validation tests. | ||
from django.test.utils import get_runner | ||
TestRunner = get_runner(settings) | ||
|
||
test_runner = TestRunner(verbosity=1, interactive=False, failfast=False) | ||
failures = test_runner.run_tests(INSTALLED_APPS) | ||
return failures | ||
|
||
|
||
if __name__ == "__main__": | ||
failures = run_tests() | ||
if failures: | ||
sys.exit(bool(failures)) |
This file was deleted.
Oops, something went wrong.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
Empty file.
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
Empty file.
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.