Skip to content

Commit b2e6e69

Browse files
committed
Update test
1 parent 0a9d5c8 commit b2e6e69

1 file changed

Lines changed: 7 additions & 0 deletions

File tree

Lib/test/test_concurrent_futures/test_interpreter_pool.py

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -485,11 +485,18 @@ def test_import_interpreter_pool_executor(self):
485485
sys.exit(1)
486486
487487
from concurrent.futures import *
488+
489+
if 'InterpreterPoolExecutor' in globals():
490+
print('InterpreterPoolExecutor should not be imported!',
491+
file=sys.stderr)
492+
sys.exit(1)
488493
""")
489494

490495
cmd = [sys.executable, '-c', code]
491496
p = subprocess.run(cmd, capture_output=True)
492497
self.assertEqual(p.returncode, 0, p.stderr.decode())
498+
self.assertEqual(p.stdout.decode(), '')
499+
self.assertEqual(p.stderr.decode(), '')
493500

494501

495502
class AsyncioTest(InterpretersMixin, testasyncio_utils.TestCase):

0 commit comments

Comments
 (0)