testwwvb: Allow redundant cast for pyrefly

mypy requires this cast, and pyright at least doesn't object.

Signed-off-by: Jeff Epler <jepler@gmail.com>
This commit is contained in:
Jeff Epler 2025-08-26 21:46:30 -05:00
parent af3defa722
commit 7e7294fc23

View file

@ -51,6 +51,7 @@ class WWVBTestCase(unittest.TestCase):
if o.startswith("--channel="):
value = o[10:]
if value in {"both", "amplitude", "phase"}:
# pyrefly: ignore # redundant-cast
channel = typing.cast("WWVBChannel", value)
else:
raise ValueError(f"Unknown channel {o!r}")