Example #1
0
def test_get_or_reraise_reraise_given_errror():
    data = (None, Exception())
    with pytest.raises(Exception):
        get_or_reraise(data)
Example #2
0
def test_get_or_reraise_return_data_if_has_no_error():
    data = ('test', None)

    result = get_or_reraise(data)

    assert result == 'test'