We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 1b184c6 commit 7abfc49Copy full SHA for 7abfc49
Lib/test/test_sys.py
@@ -850,7 +850,12 @@ def test_sys_getwindowsversion_no_instantiation(self):
850
851
@test.support.cpython_only
852
def test_clear_type_cache(self):
853
- sys._clear_type_cache()
+ with warnings.catch_warnings(record=True) as w:
854
+ warnings.simplefilter("always")
855
+ sys._clear_type_cache()
856
+ self.assertEqual(len(w), 1)
857
+ self.assertTrue(issubclass(w[0].category, DeprecationWarning))
858
+ self.assertIn("_clear_type_cache", str(w[0].message))
859
860
@force_not_colorized
861
@support.requires_subprocess()
0 commit comments