MCPcopy Index your code
hub / github.com/ray-project/ray / check_cli

Function check_cli

python/ray/serve/tests/test_cli.py:407–424  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

405 serve.run(fn.bind())
406
407 def check_cli():
408 info_response = subprocess.check_output(["serve", "config"]).decode("utf-8")
409 config_response_for_absent_app = subprocess.check_output(
410 ["serve", "config", "-n", "absent_app"]
411 ).decode("utf-8")
412 status_response = subprocess.check_output(["serve", "status"])
413 fetched_status = yaml.safe_load(status_response)["applications"][
414 SERVE_DEFAULT_APP_NAME
415 ]
416
417 assert info_response == "No configuration was found.\n"
418 assert (
419 config_response_for_absent_app
420 == 'No config has been deployed for application "absent_app".\n'
421 )
422 assert fetched_status["status"] == "RUNNING"
423 assert fetched_status["deployments"]["fn"]["status"] == "HEALTHY"
424 return True
425
426 wait_for_condition(check_cli)
427

Callers

nothing calls this directly

Calls 4

listFunction · 0.85
check_outputMethod · 0.80
decodeMethod · 0.45
valuesMethod · 0.45

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…