Skip to content

Commit 4134261

Browse files
authored
gh-121605: Fix test hang when pyrepl is not available (GH-121820)
The fallback repl does not support "exit" without parentheses, so the test would hang until the timeout expired.
1 parent e5c7216 commit 4134261

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

Lib/test/test_pyrepl/test_pyrepl.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -901,7 +901,7 @@ def setUp(self):
901901
def test_exposed_globals_in_repl(self):
902902
pre = "['__annotations__', '__builtins__'"
903903
post = "'__loader__', '__name__', '__package__', '__spec__']"
904-
output, exit_code = self.run_repl(["sorted(dir())", "exit"])
904+
output, exit_code = self.run_repl(["sorted(dir())", "exit()"])
905905
if "can't use pyrepl" in output:
906906
self.skipTest("pyrepl not available")
907907
self.assertEqual(exit_code, 0)

0 commit comments

Comments
 (0)