Remove some no longer needed type-ignores

This commit is contained in:
Ran Benita
2021-01-29 20:40:43 +02:00
parent 07f0eb26b4
commit afea190797
7 changed files with 10 additions and 15 deletions

View File

@@ -713,7 +713,7 @@ def raises(
else:
excepted_exceptions = expected_exception
for exc in excepted_exceptions:
if not isinstance(exc, type) or not issubclass(exc, BaseException): # type: ignore[unreachable]
if not isinstance(exc, type) or not issubclass(exc, BaseException):
msg = "expected exception must be a BaseException type, not {}" # type: ignore[unreachable]
not_a = exc.__name__ if isinstance(exc, type) else type(exc).__name__
raise TypeError(msg.format(not_a))