test: fix depserv.sh after regression in 0b182c06

A service that is reloaded should not trigger dependants to be reloaded
unless the new <~cond> is used.  Which is reserve for tightly coupled
services.

Signed-off-by: Joachim Wiberg <troglobit@gmail.com>
This commit is contained in:
Joachim Wiberg committed 2026-02-22 20:36:36 +01:00
1 parent 2c78e7429a
commit 804f655d87
1 file changed
+4 -4
+4 -4
View File
@@ -5,7 +5,7 @@
# - bar must not start until foo is ready
# - bar must be stopped when foo goes down
# - bar must be restarted when foo is restarted
# - bar must be restarted when foo is reloaded (per-service reload)
# - bar must not be restarted when foo is reloaded (per-service reload)
#
# Regression test bug #314, that bar is not in a restart loop when foo
# is stopped. Also, verify that changing between runlevels, where foo
@@ -50,15 +50,15 @@ test_one()
run "initctl status"
assert "bar is restarted" "$(texec initctl |grep bar | awk '{print $1;}')" != "$pid"
say "Verify bar is restarted when foo is reloaded (per-service) ..."
say "Verify bar is NOT restarted when foo is reloaded (per-service) ..."
retry 'assert_status "bar" "running"' 5 1
pid=$(texec initctl |grep bar | awk '{print $1;}')
run "initctl reload foo"
retry 'assert_status "bar" "running"' 5 1
assert "bar is restarted on reload" "$(texec initctl |grep bar | awk '{print $1;}')" != "$pid"
assert "bar is NOT restarted on reload" "$(texec initctl |grep bar | awk '{print $1;}')" == "$pid"
# Wait for spice to be stolen by the Harkonnen
sleep 3
sleep 5
# bar should now have detected the loss of spice and be in restart
run "initctl status"
assert_status "bar" "restart"