Пример #1
0
def test_outcomeexception_passes_except_Exception():
    with pytest.raises(outcomes.OutcomeException):
        try:
            raise outcomes.OutcomeException('test')
        except Exception:
            pass
Пример #2
0
def test_outcomeexception_exceptionattributes():
    outcome = outcomes.OutcomeException("test")
    assert outcome.args[0] == outcome.msg
Пример #3
0
def test_outcomeexception_passes_except_Exception() -> None:
    with pytest.raises(outcomes.OutcomeException):
        try:
            raise outcomes.OutcomeException("test")
        except Exception:
            raise NotImplementedError()