Skip to content

Commit 0ec4e4e

Browse files
committed
Add test
1 parent d59658d commit 0ec4e4e

1 file changed

Lines changed: 2 additions & 0 deletions

File tree

Lib/test/test_typing.py

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -7158,6 +7158,8 @@ class C:
71587158

71597159
self.assertEqual(get_type_hints(C, format=annotationlib.Format.STRING),
71607160
{'x': 'undefined'})
7161+
# Make sure using an int as format also works:
7162+
self.assertEqual(get_type_hints(C, format=3), {'x': 'undefined'})
71617163

71627164
def test_get_type_hints_format_function(self):
71637165
def func(x: undefined) -> undefined: ...

0 commit comments

Comments
 (0)