def METHOD_NAME(expect_shutdown: bool = False, print_error: bool = False) -> None:
    out = None
    try:
        wait_for_port_open(config.LOCAL_PORT_STEPFUNCTIONS, sleep_time=2)
        endpoint_url = f"http://127.0.0.1:{config.LOCAL_PORT_STEPFUNCTIONS}"
        out = connect_to(endpoint_url=endpoint_url).stepfunctions.list_state_machines()
    except Exception:
        if print_error:
            LOG.exception("StepFunctions health check failed")
    if expect_shutdown:
        assert out is None
    else:
        assert out and isinstance(out.get("stateMachines"), list)