tests/checks/disown: fix signal delivery race

Intermittent test failure suggests that kill(3p) returns before the
signal is delivered.  Fix the failure by waiting until the signal
has been delivered before continuing the test.

Fixes #12635
This commit is contained in:
Johannes Altmanninger
2026-04-19 17:02:22 +08:00
parent 9e4eb37696
commit 34535fcb61

View File

@@ -14,6 +14,9 @@ status job-control full
sleep 1 &
set -l pid (jobs -lp)
kill -SIGSTOP $pid
while not jobs | grep -q stopped
sleep .01
end
disown
# CHECKERR: disown: job 1 ('sleep 1 &') was stopped and has been signalled to continue.
echo $status