How to use the chaostoolkit.plan.apply_steady_probe function in chaostoolkit

To help you get started, we’ve selected a few chaostoolkit examples, based on popular ways it is used in public projects.

Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.

github chaostoolkit / chaostoolkit / tests / test_plan.py View on Github external
def test_steady_probe_needs_a_name():
    step = {
        "probes": {
            "steady": {
            }
        }
    }

    with pytest.raises(InvalidPlan) as excinfo:
        apply_steady_probe(step, layers)

    assert "steady probe requires a probe name to apply" in str(excinfo)
github chaostoolkit / chaostoolkit / tests / test_plan.py View on Github external
def test_steady_probe_must_be_implemented():
    step = {
        "probes": {
            "steady": {
                "layer": "noop",
                "name": "microservice-should-be-happy"
            }
        }
    }

    with pytest.raises(UnknownProbe) as excinfo:
        apply_steady_probe(step, layers)

    assert "probe 'microservice_should_be_happy' is not implemented" in\
        str(excinfo)
github chaostoolkit / chaostoolkit / tests / test_plan.py View on Github external
def test_a_step_without_steady_probe_is_silent():
    step = {}
    assert apply_steady_probe(step, layers) is None