]> git.ipfire.org Git - thirdparty/Python/cpython.git/commitdiff
gh-95388: Suppress deprecation warning in test_immutable_type_with_mutable_base ...
authorErlend E. Aasland <erlend.aasland@protonmail.com>
Mon, 8 Aug 2022 10:15:57 +0000 (12:15 +0200)
committerGitHub <noreply@github.com>
Mon, 8 Aug 2022 10:15:57 +0000 (12:15 +0200)
When 3.14 kicks in, it'll be a RuntimeError;
the test will correctly fail then.

Lib/test/test_capi.py

index c74355789747976353974b8b2e6d7922b717d45e..1ff14e7bc56fd57ab8ae9eb04bfb5479fde0b5ea 100644 (file)
@@ -645,6 +645,7 @@ class CAPITest(unittest.TestCase):
                 with self.assertRaises(SystemError):
                     _testcapi.create_type_from_repeated_slots(variant)
 
+    @warnings_helper.ignore_warnings(category=DeprecationWarning)
     def test_immutable_type_with_mutable_base(self):
         # Add deprecation warning here so it's removed in 3.14
         warnings._deprecated(