mirror of
https://github.com/python/cpython.git
synced 2025-08-30 13:38:43 +00:00
gh-112535: Add test on _Py_ThreadId() (#112709)
Add also test.support.Py_GIL_DISABLED constant.
This commit is contained in:
parent
a8ce149628
commit
c5fa8a54db
6 changed files with 75 additions and 8 deletions
|
@ -1224,9 +1224,7 @@ class SysModuleTest(unittest.TestCase):
|
|||
@test.support.cpython_only
|
||||
@unittest.skipUnless(hasattr(sys, 'abiflags'), 'need sys.abiflags')
|
||||
def test_disable_gil_abi(self):
|
||||
abi_threaded = 't' in sys.abiflags
|
||||
py_gil_disabled = (sysconfig.get_config_var('Py_GIL_DISABLED') == 1)
|
||||
self.assertEqual(py_gil_disabled, abi_threaded)
|
||||
self.assertEqual('t' in sys.abiflags, support.Py_GIL_DISABLED)
|
||||
|
||||
|
||||
@test.support.cpython_only
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue