Beispiel #1
0
def test_sensu_event_for_last_run_state_invalid():
    with raises(ValueError):
        check_chronos_jobs.sensu_event_for_last_run_state(100)
Beispiel #2
0
def test_sensu_event_for_last_run_state_not_run():
    result = check_chronos_jobs.sensu_event_for_last_run_state(chronos_tools.LastRunState.NotRun)
    assert result == pysensu_yelp.Status.OK
Beispiel #3
0
def test_sensu_event_for_last_run_state_fail():
    result = check_chronos_jobs.sensu_event_for_last_run_state(chronos_tools.LastRunState.Fail)
    assert result == pysensu_yelp.Status.CRITICAL
def test_sensu_event_for_last_run_state_invalid():
    with raises(ValueError):
        check_chronos_jobs.sensu_event_for_last_run_state(100)
def test_sensu_event_for_last_run_state_not_run():
    result = check_chronos_jobs.sensu_event_for_last_run_state(chronos_tools.LastRunState.NotRun)
    assert result == pysensu_yelp.Status.OK
def test_sensu_event_for_last_run_state_fail():
    result = check_chronos_jobs.sensu_event_for_last_run_state(chronos_tools.LastRunState.Fail)
    assert result == pysensu_yelp.Status.CRITICAL