Skip to content

Commit fe138af

Browse files
test(e2e): add --ignore-not-found to vminstance.bats end-of-test deletes
Symmetrize the post-success cleanup on lines 83-84 with the pre-clean shape on lines 12-13/41. Without --ignore-not-found, a race that already removed the resource (e.g., a parallel teardown or finalizer-driven GC) turns a passing test into a failure after assertions have already run. Review feedback PR #2555 (lexfrei follow-up #1). Signed-off-by: Myasnikov Daniil <[email protected]>
1 parent 25180c5 commit fe138af

1 file changed

Lines changed: 2 additions & 2 deletions

File tree

‎hack/e2e-apps/vminstance.bats‎

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -80,6 +80,6 @@ EOF
8080
kubectl -n tenant-test wait hr vm-instance-$name --timeout=60s --for=condition=ready
8181
# VM ready follows IP assignment closely; 60s gives buffer for the qemu-guest-agent.
8282
kubectl -n tenant-test wait vm vm-instance-$name --timeout=60s --for=condition=ready
83-
kubectl -n tenant-test delete vminstances.apps.cozystack.io $name --timeout=3m
84-
kubectl -n tenant-test delete vmdisks.apps.cozystack.io $diskName --timeout=3m
83+
kubectl -n tenant-test delete vminstances.apps.cozystack.io $name --ignore-not-found --timeout=3m
84+
kubectl -n tenant-test delete vmdisks.apps.cozystack.io $diskName --ignore-not-found --timeout=3m
8585
}

0 commit comments

Comments
 (0)