#29363: Use unittest assertWarns methods instead of warnings.catch_warnings/simplefilter/assertions in the test suite. ------------------------------------------------+------------------------ Reporter: Simon Charette | Owner: nobody Type: Cleanup/optimization | Status: new Component: Testing framework | Version: 2.0 Severity: Normal | Keywords: Triage Stage: Unreviewed | Has patch: 0 Needs documentation: 0 | Needs tests: 0 Patch needs improvement: 0 | Easy pickings: 0 UI/UX: 0 | ------------------------------------------------+------------------------ The `assertWarns` and `assertWarnsRegex` method have been introduced in Python 3.2 and should remove a lot of boilerplate around warnings testing in the test suite.
https://docs.python.org/3/library/unittest.html#unittest.TestCase.assertWarns -- Ticket URL: <https://code.djangoproject.com/ticket/29363> Django <https://code.djangoproject.com/> The Web framework for perfectionists with deadlines. -- You received this message because you are subscribed to the Google Groups "Django updates" group. To unsubscribe from this group and stop receiving emails from it, send an email to django-updates+unsubscr...@googlegroups.com. To post to this group, send email to django-updates@googlegroups.com. To view this discussion on the web visit https://groups.google.com/d/msgid/django-updates/052.73f66943a8bd45ca36a75b7263a24df1%40djangoproject.com. For more options, visit https://groups.google.com/d/optout.