From: Ivan Kruglov Date: Mon, 18 May 2026 07:45:23 +0000 (-0700) Subject: test: wait systemd to finish reexec in TEST-74-AUX-UTILS.varlinkctl.sh X-Git-Tag: v261-rc1~80^2~1 X-Git-Url: http://git.ipfire.org/gitweb/index.cgi?a=commitdiff_plain;h=e86b49473ffe3eba66b02011e2fb825248784a41;p=thirdparty%2Fsystemd.git test: wait systemd to finish reexec in TEST-74-AUX-UTILS.varlinkctl.sh --- diff --git a/test/units/TEST-74-AUX-UTILS.varlinkctl.sh b/test/units/TEST-74-AUX-UTILS.varlinkctl.sh index 0836883f24c..ec71e2641e0 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.Manager in user manager testuser_uid=$(id -u testuser)