From 61e20bb945c8af9430abdca3a70ecfaf011bb893 Mon Sep 17 00:00:00 2001 From: Jakob Meng Date: Mon, 14 Mar 2022 10:54:08 +0100 Subject: [PATCH] Fix assertion after stack deletion After a stack has been removed with module stack, a call to module stack_info might still return this stack with its status set to 'DELETE_COMPLETE' and its status_reason defined as 'Stack DELETE completed successfully'. Change-Id: Ice843c403669b4a4e1b12ec73db1fb00d1405980 --- ci/roles/orchestration/tasks/main.yaml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ci/roles/orchestration/tasks/main.yaml b/ci/roles/orchestration/tasks/main.yaml index 0818cac1..b205d46f 100644 --- a/ci/roles/orchestration/tasks/main.yaml +++ b/ci/roles/orchestration/tasks/main.yaml @@ -41,4 +41,4 @@ - assert: that: - stacks is defined - - stacks['stacks']|length == 0 + - (stacks['stacks']|length == 0) or (stacks['stacks'][0]['status'] == 'DELETE_COMPLETE')