summaryrefslogtreecommitdiffstats
path: root/Lib/test/test_sys.py
diff options
context:
space:
mode:
authorVictor Stinner <vstinner@redhat.com>2019-06-25 01:01:08 (GMT)
committerGitHub <noreply@github.com>2019-06-25 01:01:08 (GMT)
commit36456df13843c5b8a1fb5a6022ab9ed1fe2a11c5 (patch)
tree72d392c36e3deeff6a76966ecffca4623a1e72d6 /Lib/test/test_sys.py
parent9fc720e5e4f772598013ea48a3f0d22b2b6b04fa (diff)
downloadcpython-36456df13843c5b8a1fb5a6022ab9ed1fe2a11c5.zip
cpython-36456df13843c5b8a1fb5a6022ab9ed1fe2a11c5.tar.gz
cpython-36456df13843c5b8a1fb5a6022ab9ed1fe2a11c5.tar.bz2
bpo-37392: Remove sys.setcheckinterval() (GH-14355)
Remove sys.getcheckinterval() and sys.setcheckinterval() functions. They were deprecated since Python 3.2. Use sys.getswitchinterval() and sys.setswitchinterval() instead. Remove also check_interval field of the PyInterpreterState structure.
Diffstat (limited to 'Lib/test/test_sys.py')
-rw-r--r--Lib/test/test_sys.py9
1 files changed, 0 insertions, 9 deletions
diff --git a/Lib/test/test_sys.py b/Lib/test/test_sys.py
index 49f2722..c223f92 100644
--- a/Lib/test/test_sys.py
+++ b/Lib/test/test_sys.py
@@ -159,15 +159,6 @@ class SysModuleTest(unittest.TestCase):
# testing sys.settrace() is done in test_sys_settrace.py
# testing sys.setprofile() is done in test_sys_setprofile.py
- def test_setcheckinterval(self):
- with warnings.catch_warnings():
- warnings.simplefilter("ignore")
- self.assertRaises(TypeError, sys.setcheckinterval)
- orig = sys.getcheckinterval()
- for n in 0, 100, 120, orig: # orig last to restore starting state
- sys.setcheckinterval(n)
- self.assertEqual(sys.getcheckinterval(), n)
-
def test_switchinterval(self):
self.assertRaises(TypeError, sys.setswitchinterval)
self.assertRaises(TypeError, sys.setswitchinterval, "a")