[ty] Fix tiny mistake in protocol tests (#20743)

This commit is contained in:
David Peter 2025-10-07 13:58:35 +02:00 committed by GitHub
parent f90d6466e0
commit 23ebfe7777
No known key found for this signature in database
GPG key ID: B5690EEEBB952194

View file

@ -964,11 +964,14 @@ class Foo(Protocol):
def __init__(self) -> None:
self.x = 42 # fine
self.a = 56 # TODO: should emit diagnostic
self.b: int = 128 # TODO: should emit diagnostic
def non_init_method(self) -> None:
self.y = 64 # fine
self.x = 64 # fine
self.y = "bar" # fine
self.c = 72 # TODO: should emit diagnostic
# Note: the list of members does not include `a`, `b` or `c`,