1
0
mirror of https://github.com/django/django.git synced 2025-10-25 14:46:09 +00:00

newforms-admin: Merged to [4616]

git-svn-id: http://code.djangoproject.com/svn/django/branches/newforms-admin@4617 bcc190cf-cafb-0310-a4f2-bffc1f526a37
This commit is contained in:
Adrian Holovaty
2007-02-26 20:17:26 +00:00
parent a9fafd521f
commit 6df0230077
69 changed files with 6224 additions and 2834 deletions

View File

@@ -63,6 +63,8 @@ def run_tests(module_list, verbosity=1, extra_tests=[]):
looking for doctests and unittests in models.py or tests.py within
the module. A list of 'extra' tests may also be provided; these tests
will be added to the test suite.
Returns the number of tests that failed.
"""
setup_test_environment()
@@ -77,7 +79,10 @@ def run_tests(module_list, verbosity=1, extra_tests=[]):
old_name = settings.DATABASE_NAME
create_test_db(verbosity)
unittest.TextTestRunner(verbosity=verbosity).run(suite)
result = unittest.TextTestRunner(verbosity=verbosity).run(suite)
destroy_test_db(old_name, verbosity)
teardown_test_environment()
return len(result.failures)