test: Extend depserv test with per-service reload, fix slay race

Verify that 'initctl reload foo' properly triggers dependent
services by checking that bar gets a new PID after the reload.
Also change the second test case from service/foo/running to
service/foo/ready which is the actual condition set by pidfile.so.

Fix a race in slay where the target process could exit between
the PID lookup and kill -9, causing spurious test failures in
tight kill loops (e.g., start-kill-service.sh).

Signed-off-by: Joachim Wiberg <troglobit@gmail.com>
This commit is contained in:
Joachim Wiberg committed 2026-02-10 16:00:57 +01:00
1 parent f0914f6d32
commit 0b182c063e
3 files changed
+18 -3

No files matched your search

+1 -1
View File
@@ -52,4 +52,4 @@ done
echo "$pid" > /tmp/oldpid
#echo "PID $pid, kill -9 ..."
kill -9 "$pid"
kill -9 "$pid" 2>/dev/null || true