From 2a22af6d8bd9cde6431849eed37483b84971c521 Mon Sep 17 00:00:00 2001 From: Yang Chiu Date: Mon, 25 Dec 2023 15:37:12 +0800 Subject: [PATCH] test: shorten check interval in wait_for_engine_image_condition Signed-off-by: Yang Chiu --- manager/integration/tests/common.py | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/manager/integration/tests/common.py b/manager/integration/tests/common.py index 8da9d47f91..b65d480f28 100644 --- a/manager/integration/tests/common.py +++ b/manager/integration/tests/common.py @@ -66,6 +66,7 @@ RETRY_COUNTS_SHORT = 30 RETRY_COUNTS_LONG = 360 RETRY_INTERVAL = 1 +RETRY_INTERVAL_SHORT = 0.5 RETRY_INTERVAL_LONG = 2 RETRY_BACKUP_COUNTS = 300 RETRY_BACKUP_INTERVAL = 1 @@ -2167,7 +2168,7 @@ def wait_for_engine_image_creation(client, image_name): break if found: break - time.sleep(RETRY_INTERVAL) + time.sleep(RETRY_INTERVAL_SHORT) assert found @@ -2191,7 +2192,7 @@ def wait_for_engine_image_condition(client, image_name, state): image = client.by_id_engine_image(image_name) if image['conditions'][0]['status'] == state: break - time.sleep(RETRY_INTERVAL_LONG) + time.sleep(RETRY_INTERVAL_SHORT) assert image['conditions'][0]['status'] == state return image