From 64609cbe223fb429dcd324e3b558b67878fb442a Mon Sep 17 00:00:00 2001 From: Sasha Belousov <141743480+BelSasha@users.noreply.github.com> Date: Thu, 13 Jun 2024 23:22:04 +0300 Subject: [PATCH] minor changes to cluster status tests (#891) Co-authored-by: Alexandra Belousov --- tests/test_resources/test_clusters/test_cluster.py | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/tests/test_resources/test_clusters/test_cluster.py b/tests/test_resources/test_clusters/test_cluster.py index 177e724ca..1247c36a0 100644 --- a/tests/test_resources/test_clusters/test_cluster.py +++ b/tests/test_resources/test_clusters/test_cluster.py @@ -663,7 +663,7 @@ def test_send_status_to_db(self, cluster): headers=headers, ) assert get_status_data_resp.status_code == 200 - get_status_data = get_status_data_resp.json()["data"] + get_status_data = get_status_data_resp.json()["data"][0] assert get_status_data["resource_type"] == status.get("cluster_config").get( "resource_type" ) @@ -681,7 +681,7 @@ def test_send_status_to_db(self, cluster): f"{api_server_url}/resource/{cluster_uri}/cluster/status", headers=headers, ) - assert get_status_data_resp.json()["data"]["status"] == "terminated" + assert get_status_data_resp.json()["data"][0]["status"] == "terminated" @pytest.mark.level("minimal") def test_status_scheduler_basic_flow(self, cluster): @@ -715,4 +715,4 @@ def test_status_scheduler_basic_flow(self, cluster): ) assert get_status_data_resp.status_code == 200 - assert get_status_data_resp.json()["data"]["status"] == "running" + assert get_status_data_resp.json()["data"][0]["status"] == "running"