|
11 | 11 | import unittest
|
12 | 12 | from test import support
|
13 | 13 | from test.support import os_helper
|
14 |
| -from test.support import force_not_colorized |
| 14 | +from test.support import force_not_colorized, warnings_helper |
15 | 15 | from test.support import threading_helper
|
16 | 16 | from test.support.script_helper import (
|
17 | 17 | spawn_python, kill_python, assert_python_ok, assert_python_failure,
|
@@ -932,14 +932,14 @@ def test_python_asyncio_debug(self):
|
932 | 932 | self.assertIn(b'True', out)
|
933 | 933 |
|
934 | 934 | @unittest.skipUnless(sysconfig.get_config_var('Py_TRACE_REFS'), "Requires --with-trace-refs build option")
|
935 |
| - @support.ignore_warnings(category=DeprecationWarning) |
| 935 | + @warnings_helper.ignore_warnings(category=DeprecationWarning) |
936 | 936 | def test_python_dump_refs(self):
|
937 | 937 | code = 'import sys; sys._clear_type_cache()'
|
938 | 938 | rc, out, err = assert_python_ok('-c', code, PYTHONDUMPREFS='1')
|
939 | 939 | self.assertEqual(rc, 0)
|
940 | 940 |
|
941 | 941 | @unittest.skipUnless(sysconfig.get_config_var('Py_TRACE_REFS'), "Requires --with-trace-refs build option")
|
942 |
| - @support.ignore_warnings(category=DeprecationWarning) |
| 942 | + @warnings_helper.ignore_warnings(category=DeprecationWarning) |
943 | 943 | def test_python_dump_refs_file(self):
|
944 | 944 | with tempfile.NamedTemporaryFile() as dump_file:
|
945 | 945 | code = 'import sys; sys._clear_type_cache()'
|
|
0 commit comments