aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/Lib/test/test_interpreters/test_api.py
diff options
context:
space:
mode:
Diffstat (limited to 'Lib/test/test_interpreters/test_api.py')
-rw-r--r--Lib/test/test_interpreters/test_api.py3
1 files changed, 3 insertions, 0 deletions
diff --git a/Lib/test/test_interpreters/test_api.py b/Lib/test/test_interpreters/test_api.py
index 5e3d7a052ba..a9befbba64d 100644
--- a/Lib/test/test_interpreters/test_api.py
+++ b/Lib/test/test_interpreters/test_api.py
@@ -54,6 +54,9 @@ class CreateTests(TestBase):
self.assertIsInstance(interp, interpreters.Interpreter)
self.assertIn(interp, interpreters.list_all())
+ # GH-126221: Passing an invalid Unicode character used to cause a SystemError
+ self.assertRaises(UnicodeEncodeError, _interpreters.create, '\udc80')
+
def test_in_thread(self):
lock = threading.Lock()
interp = None