Author: russellm Date: 2011-04-02 01:41:26 -0700 (Sat, 02 Apr 2011) New Revision: 15986
Modified: django/trunk/django/test/client.py django/trunk/django/test/simple.py Log: Advanced deprecations in django.test. Modified: django/trunk/django/test/client.py =================================================================== --- django/trunk/django/test/client.py 2011-04-02 08:41:03 UTC (rev 15985) +++ django/trunk/django/test/client.py 2011-04-02 08:41:26 UTC (rev 15986) @@ -421,7 +421,7 @@ # Provide a backwards-compatible (but pending deprecation) response.template def _get_template(self): warnings.warn("response.template is deprecated; use response.templates instead (which is always a list)", - PendingDeprecationWarning, stacklevel=2) + DeprecationWarning, stacklevel=2) if not self.templates: return None elif len(self.templates) == 1: Modified: django/trunk/django/test/simple.py =================================================================== --- django/trunk/django/test/simple.py 2011-04-02 08:41:03 UTC (rev 15985) +++ django/trunk/django/test/simple.py 2011-04-02 08:41:26 UTC (rev 15986) @@ -19,7 +19,7 @@ import warnings warnings.warn( "DjangoTestRunner is deprecated; it's functionality is indistinguishable from TextTestRunner", - PendingDeprecationWarning + DeprecationWarning ) super(DjangoTestRunner, self).__init__(*args, **kwargs) @@ -355,12 +355,3 @@ self.teardown_databases(old_config) self.teardown_test_environment() return self.suite_result(suite, result) - -def run_tests(test_labels, verbosity=1, interactive=True, failfast=False, extra_tests=None): - import warnings - warnings.warn( - 'The run_tests() test runner has been deprecated in favor of DjangoTestSuiteRunner.', - DeprecationWarning - ) - test_runner = DjangoTestSuiteRunner(verbosity=verbosity, interactive=interactive, failfast=failfast) - return test_runner.run_tests(test_labels, extra_tests=extra_tests) -- You received this message because you are subscribed to the Google Groups "Django updates" group. To post to this group, send email to django-updates@googlegroups.com. To unsubscribe from this group, send email to django-updates+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/django-updates?hl=en.