From 1605bb2d96e3da44602b970d78181bde86b6f337 Mon Sep 17 00:00:00 2001 From: Cooper Tseng Date: Mon, 2 Sep 2024 17:53:47 +0800 Subject: [PATCH] Fix incorrect if-condition in test_create_with_invalid_url Signed-off-by: Cooper Tseng --- harvester_e2e_tests/apis/test_images.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/harvester_e2e_tests/apis/test_images.py b/harvester_e2e_tests/apis/test_images.py index a86308d84..6b29bfec9 100644 --- a/harvester_e2e_tests/apis/test_images.py +++ b/harvester_e2e_tests/apis/test_images.py @@ -236,7 +236,7 @@ def test_create_with_invalid_url(api_client, gen_unique_name, wait_timeout): while endtime > datetime.now(): code, data = api_client.images.get(unique_name) image_conds = data.get('status', {}).get('conditions', []) - if len(image_conds) > 0: + if "Initialized" == image_conds[-1].get("type"): break sleep(3)