Skip to content

Commit eb838cd

Browse files
committed
Include model_repository_index API into _assert_model_ready()
1 parent 8360cfc commit eb838cd

File tree

1 file changed

+8
-0
lines changed

1 file changed

+8
-0
lines changed

ci/L0_check_health_vllm/check_health_test.py

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -90,7 +90,15 @@ def _assert_infer_exception(self, expected_exception_message):
9090

9191
def _assert_model_ready(self, expected_readiness):
9292
with grpcclient.InferenceServerClient(self._grpc_url) as client:
93+
# is_model_ready API
9394
assert client.is_model_ready(self._model_name) == expected_readiness
95+
# get_model_repository_index API
96+
model_state = None
97+
for model_index in client.get_model_repository_index().models:
98+
if model_index.name == self._model_name:
99+
assert model_state == None, "duplicate model index found"
100+
model_state = model_index.state == "READY"
101+
assert model_state == expected_readiness
94102

95103
def test_vllm_is_healthy(self):
96104
num_repeats = 3

0 commit comments

Comments
 (0)