From 4a58adfb7febdc530c1f57d987e37993f3527aac Mon Sep 17 00:00:00 2001 From: Ed Santiago Date: Thu, 11 Jan 2024 13:03:11 -0700 Subject: [PATCH] systests: kube with policies test: fix race Add a wait_for_ready() to one kube-play test, to make sure container output has made it to the journal. Probably does not fix #18501, but I think it might fix its most common presentation. Signed-off-by: Ed Santiago --- test/system/260-sdnotify.bats | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/test/system/260-sdnotify.bats b/test/system/260-sdnotify.bats index 81516c9e1d..ac54ae8452 100644 --- a/test/system/260-sdnotify.bats +++ b/test/system/260-sdnotify.bats @@ -269,7 +269,7 @@ spec: - command: - /bin/sh - -c - - 'printenv NOTIFY_SOCKET; while ! test -f /stop;do sleep 0.1;done' + - 'printenv NOTIFY_SOCKET; echo READY; while ! test -f /stop;do sleep 0.1;done' image: $SYSTEMD_IMAGE name: a - command: @@ -309,6 +309,7 @@ EOF die "container $container_a and/or $container_b did not start" fi + wait_for_ready $container_a # Make sure the containers have the correct policy run_podman container inspect $container_a $container_b $service_container --format "{{.Config.SdNotifyMode}}" is "$output" "container