Fix mypy
This commit is contained in:
parent
b5d5c7f4d3
commit
342cd9585a
|
|
@ -178,8 +178,7 @@ def _select_wrapper(args: Optional[argparse.Namespace]) -> SelectionInfo:
|
|||
return SelectionInfo(wrapper=env_wrapper, reason=SelectionReason.env)
|
||||
|
||||
if _WRAPPER_OVERRIDE is not None:
|
||||
pass # type: ignore[unreachable]
|
||||
assert _WRAPPER_OVERRIDE in WRAPPERS, _WRAPPER_OVERRIDE
|
||||
assert _WRAPPER_OVERRIDE in WRAPPERS # type: ignore[unreachable]
|
||||
return SelectionInfo(wrapper=_WRAPPER_OVERRIDE, reason=SelectionReason.override)
|
||||
|
||||
return _autoselect_wrapper()
|
||||
|
|
|
|||
|
|
@ -380,7 +380,7 @@ class TestSelectWrapper:
|
|||
|
||||
def test_invalid_override(self, monkeypatch: pytest.MonkeyPatch):
|
||||
monkeypatch.setattr(machinery, "_WRAPPER_OVERRIDE", "invalid")
|
||||
with pytest.raises(AssertionError, match="invalid"):
|
||||
with pytest.raises(AssertionError):
|
||||
machinery._select_wrapper(args=None)
|
||||
|
||||
|
||||
|
|
|
|||
Loading…
Reference in New Issue