summaryrefslogtreecommitdiffstats
path: root/Lib/test/test_exceptions.py
diff options
context:
space:
mode:
Diffstat (limited to 'Lib/test/test_exceptions.py')
-rw-r--r--Lib/test/test_exceptions.py7
1 files changed, 7 insertions, 0 deletions
diff --git a/Lib/test/test_exceptions.py b/Lib/test/test_exceptions.py
index 7f1d5ee..8ccf087 100644
--- a/Lib/test/test_exceptions.py
+++ b/Lib/test/test_exceptions.py
@@ -1844,6 +1844,13 @@ class NameErrorTests(unittest.TestCase):
self.assertIn("nonsense", err.getvalue())
self.assertIn("ZeroDivisionError", err.getvalue())
+ def test_gh_111654(self):
+ def f():
+ class TestClass:
+ TestClass
+
+ self.assertRaises(NameError, f)
+
# Note: name suggestion tests live in `test_traceback`.