test runner

This commit is contained in:
nitely 2014-05-09 19:32:31 -03:00
parent db53d2ab86
commit 074d9b2756
4 changed files with 22 additions and 1 deletions

View File

@ -7,4 +7,4 @@ install:
- pip install -r requirements.txt --use-mirrors
script:
- "python manage.py test spirit.tests"
- "python setup.py test"

View File

@ -0,0 +1,2 @@
from settings import *
from local_settings_sample import *

18
run_tests.py Normal file
View File

@ -0,0 +1,18 @@
#-*- coding: utf-8 -*-
import os
import sys
os.environ['DJANGO_SETTINGS_MODULE'] = 'example.settings_test_runner'
from django.test.runner import DiscoverRunner
def run_tests():
test_runner = DiscoverRunner()
failures = test_runner.run_tests(["spirit", ])
sys.exit(failures)
if __name__ == "__main__":
run_tests()

View File

@ -21,6 +21,7 @@ setup(
packages=[
'spirit',
],
test_suite="run_tests.run_tests",
include_package_data=True,
zip_safe=False,
install_requires=REQUIREMENTS,