From 7c39452031a4e81a2e366b923c744f7746fdf0e0 Mon Sep 17 00:00:00 2001 From: Ivan Kruglov Date: Mon, 18 May 2026 00:45:23 -0700 Subject: [PATCH] test: wait systemd to finish reexec in TEST-74-AUX-UTILS.varlinkctl.sh (cherry picked from commit e86b49473ffe3eba66b02011e2fb825248784a41) --- test/units/TEST-74-AUX-UTILS.varlinkctl.sh | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/test/units/TEST-74-AUX-UTILS.varlinkctl.sh b/test/units/TEST-74-AUX-UTILS.varlinkctl.sh index dc5f952e592..4bb992b96e4 100755 --- a/test/units/TEST-74-AUX-UTILS.varlinkctl.sh +++ b/test/units/TEST-74-AUX-UTILS.varlinkctl.sh @@ -204,6 +204,14 @@ varlinkctl call /run/systemd/io.systemd.Manager io.systemd.Manager.Describe '{}' varlinkctl call /run/systemd/io.systemd.Manager io.systemd.Manager.Reload '{}' # This will disconnect and fail, as the manager reexec and drops connections varlinkctl call /run/systemd/io.systemd.Manager io.systemd.Manager.Reexecute '{}' ||: +# Wait for the manager to finish re-exec before proceeding — the user manager +# tests below use systemd-run which requires a functional PID 1. +for _ in {1..10}; do + if systemctl is-system-running 2>/dev/null | grep -qE 'running|degraded'; then + break + fi + sleep 1 +done # test io.systemd.Network varlinkctl info /run/systemd/netif/io.systemd.Network