1
0
mirror of https://github.com/django/django.git synced 2025-01-07 17:06:04 +00:00
django/tests/test_runner/deprecation_app/tests.py
Preston Holmes e79b857a07 Fixed #18985 -- ensure module level deprecations are displayed
Also don't compete with -W CLI option.

Thanks to Aymeric Augustin for the catch, and Claude Paroz for the patch.
2013-03-24 22:06:02 -07:00

12 lines
248 B
Python

import warnings
from django.test import TestCase
warnings.warn("module-level warning from deprecation_app", DeprecationWarning)
class DummyTest(TestCase):
def test_warn(self):
warnings.warn("warning from test", DeprecationWarning)