From cf508ee2283d3d1b710279bc3d2688a6685dc96f Mon Sep 17 00:00:00 2001 From: Fabian Homborg Date: Sat, 25 Jan 2020 14:06:34 +0100 Subject: [PATCH] tests/job-ids: Wait for job to die It was possible to start the new job and execute `jobs` again before the job died (or we noticed it did), so the test would fail. To properly test, we need to ensure the job has been removed. `wait` should do it. --- tests/checks/job-ids.fish | 2 ++ 1 file changed, 2 insertions(+) diff --git a/tests/checks/job-ids.fish b/tests/checks/job-ids.fish index ecd8ad2c6..e94d2d800 100644 --- a/tests/checks/job-ids.fish +++ b/tests/checks/job-ids.fish @@ -33,6 +33,8 @@ jobs status job-control interactive command kill -9 $tokill[2] +# Wait for the job to die - the signal needs to be delivered. +wait $tokill[2] 2>/dev/null set -e tokill[2] status job-control full sleep 400 &