def METHOD_NAME(es):
    four_delta = Timedelta(4, "observations")
    assert not four_delta.is_absolute()
    assert four_delta.get_value("o") == 4
    neg_four_delta = -four_delta
    assert not neg_four_delta.is_absolute()
    assert neg_four_delta.get_value("o") == -4
    time = pd.to_datetime("2019-05-01")
    error_txt = "Invalid unit"
    with pytest.raises(Exception, match=error_txt):
        time + four_delta
    with pytest.raises(Exception, match=error_txt):
        time - four_delta