From 6fa064f991dc59c2ae7e72e828092613142bb974 Mon Sep 17 00:00:00 2001 From: Paul Holzinger Date: Tue, 28 May 2024 12:23:24 +0200 Subject: [PATCH] test/system: speed up podman container rm ... Use only one retry and a short stop timeout to speed them up. I am not sure if this will cause flakes, I have not seen any after trying for some time so I think this works just as well. And is about 2-3 seconds faster for both tests. If it does start to flake we can revert this commit again or write the test differently. Signed-off-by: Paul Holzinger --- test/system/055-rm.bats | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/test/system/055-rm.bats b/test/system/055-rm.bats index c8169746ec..cfd2adf009 100644 --- a/test/system/055-rm.bats +++ b/test/system/055-rm.bats @@ -124,10 +124,10 @@ function __run_healthcheck_container() { run_podman run -d --name $1 \ --health-cmd /bin/false \ --health-interval 1s \ - --health-retries 2 \ + --health-retries 1 \ --health-timeout 1s \ --health-on-failure=stop \ - --stop-timeout=2 \ + --stop-timeout=1 \ --health-start-period 0 \ --stop-signal SIGTERM \ $IMAGE sleep infinity @@ -156,7 +156,7 @@ function __run_healthcheck_container() { assert "$output" =~ "Error: cannot remove container $cid as it is .* - running or paused containers cannot be removed without force: container state improper" \ "Expected error message from podman rm" rm_failures=$((rm_failures + 1)) - sleep 1 + sleep 0.5 done # At this point, container should be gone