Update test_types.py

This commit is contained in:
Jeremiah Lowin 2025-05-04 14:34:37 -04:00
commit 55e62a0c63

View file

@ -256,3 +256,11 @@ class TestFindKwargByType:
pass
assert find_kwarg_by_type(func, SENTINEL) is None # type: ignore
def test_missing_type_annotation(self):
"""Test finding parameter with a missing type annotation."""
def func(a: int, b, c: str):
pass
assert find_kwarg_by_type(func, str) == "c"