Example #1
0
def test_and_with_err_ok():
    x = Err(Exception('early'))
    y = Ok(2)

    assert x.and_(y) == Err(Exception('early'))
Example #2
0
def test_and_with_err_err():
    x = Err(Exception('early'))
    y = Err(Exception('late'))

    assert x.and_(y) == Err(Exception('early'))