diff options
Diffstat (limited to 'Lib/test/test_typing.py')
-rw-r--r-- | Lib/test/test_typing.py | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/Lib/test/test_typing.py b/Lib/test/test_typing.py index 459af25..c84ff0f 100644 --- a/Lib/test/test_typing.py +++ b/Lib/test/test_typing.py @@ -1604,6 +1604,16 @@ class ProtocolTests(BaseTestCase): with self.assertRaisesRegex(TypeError, "@runtime_checkable"): isinstance(1, P) + def test_super_call_init(self): + class P(Protocol): + x: int + + class Foo(P): + def __init__(self): + super().__init__() + + Foo() # Previously triggered RecursionError + class GenericTests(BaseTestCase): |