test: Fix waiting for Finit PID

Signed-off-by: Jacques de Laval <jacques@de-laval.se>
This commit is contained in:
Jacques de Laval
2021-02-22 15:22:32 +01:00
parent 8f55bf140e
commit 9d3d211b6b
+2 -4
View File
@@ -66,10 +66,8 @@ log "$color_reset" '--' ''
finit_ppid=$!
for _ in $(seq 1 50); do
sleep 0.1
finit_pid=$(pgrep -P "$finit_ppid")
if [ "$finit_pid" ]; then
break
fi
finit_pid=$(pgrep -P "$finit_ppid") || continue
break
done
tty=/dev/$(texec cat /sys/class/tty/console/active)