]> granicus.if.org Git - python/commitdiff
Make sure warnings are not suppressed when testing for the raised
authorBrett Cannon <bcannon@gmail.com>
Sat, 10 May 2008 03:16:38 +0000 (03:16 +0000)
committerBrett Cannon <bcannon@gmail.com>
Sat, 10 May 2008 03:16:38 +0000 (03:16 +0000)
DeprecationWarning.

Lib/test/test_py3kwarn.py

index 77b0d7d621749de460426ede8b3623885d4985a3..e98480321017693d13bc30a4070bcd5455e1c390 100644 (file)
@@ -142,7 +142,7 @@ class TestStdlibRemovals(unittest.TestCase):
             original_module = sys.modules[module_name]
             del sys.modules[module_name]
         try:
-            with catch_warning() as w:
+            with catch_warning(record=False) as w:
                 warnings.filterwarnings("error", ".+ removed",
                                         DeprecationWarning)
                 try: