From e32e125a650288a698f07d4e21082572d082216e Mon Sep 17 00:00:00 2001 From: Mateusz Sikora Date: Fri, 2 May 2014 23:50:54 +0200 Subject: [PATCH] missed file --- rest_auth/runtests.py | 17 +++++++++++++++++ 1 file changed, 17 insertions(+) create mode 100644 rest_auth/runtests.py diff --git a/rest_auth/runtests.py b/rest_auth/runtests.py new file mode 100644 index 0000000..88a0126 --- /dev/null +++ b/rest_auth/runtests.py @@ -0,0 +1,17 @@ +#This file mainly exists to allow python setup.py test to work. +import os, sys +os.environ['DJANGO_SETTINGS_MODULE'] = 'test_settings' +test_dir = os.path.dirname(__file__) +sys.path.insert(0, test_dir) + +from django.test.utils import get_runner +from django.conf import settings + +def runtests(): + TestRunner = get_runner(settings) + test_runner = TestRunner(verbosity=1, interactive=True) + failures = test_runner.run_tests(['rest_auth']) + sys.exit(bool(failures)) + +if __name__ == '__main__': + runtests()