mirror of
https://github.com/python/cpython.git
synced 2025-08-04 08:59:19 +00:00
gh-76785: Update test.support.interpreters to Align With PEP 734 (gh-115566)
This brings the code under test.support.interpreters, and the corresponding extension modules, in line with recent updates to PEP 734. (Note: PEP 734 has not been accepted at this time. However, we are using an internal copy of the implementation in the test suite to exercise the existing subinterpreters feature.)
This commit is contained in:
parent
67c19e57b5
commit
e80abd57a8
11 changed files with 622 additions and 155 deletions
|
@ -729,7 +729,7 @@ class SysModuleTest(unittest.TestCase):
|
|||
self.assertIs(t, s)
|
||||
|
||||
interp = interpreters.create()
|
||||
interp.exec_sync(textwrap.dedent(f'''
|
||||
interp.exec(textwrap.dedent(f'''
|
||||
import sys
|
||||
t = sys.intern({s!r})
|
||||
assert id(t) != {id(s)}, (id(t), {id(s)})
|
||||
|
@ -744,7 +744,7 @@ class SysModuleTest(unittest.TestCase):
|
|||
t = sys.intern(s)
|
||||
|
||||
interp = interpreters.create()
|
||||
interp.exec_sync(textwrap.dedent(f'''
|
||||
interp.exec(textwrap.dedent(f'''
|
||||
import sys
|
||||
t = sys.intern({s!r})
|
||||
assert id(t) == {id(t)}, (id(t), {id(t)})
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue