diff --git a/tests/quickshell/focus-session-expiry.sh b/tests/quickshell/focus-session-expiry.sh index b34acf2..178087f 100755 --- a/tests/quickshell/focus-session-expiry.sh +++ b/tests/quickshell/focus-session-expiry.sh @@ -24,7 +24,14 @@ chmod --reference="$state_file" "$expired" mv "$expired" "$state_file" qs kill >/dev/null -qs --daemonize >/dev/null +for _ in $(seq 1 50); do + qs list 2>&1 | rg -q '^Instance ' || break + sleep 0.1 +done +if qs list 2>&1 | rg -q '^Instance '; then + fail 'shell did not stop before restart' +fi +quickshell --daemonize >/dev/null status="" for _ in $(seq 1 60); do diff --git a/tests/quickshell/focus-session-restart.sh b/tests/quickshell/focus-session-restart.sh index 268860d..6bed0ce 100755 --- a/tests/quickshell/focus-session-restart.sh +++ b/tests/quickshell/focus-session-restart.sh @@ -18,7 +18,14 @@ qs ipc call focus pause >/dev/null before=$(qs ipc call focus status) qs kill >/dev/null -qs --daemonize >/dev/null +for _ in $(seq 1 50); do + qs list 2>&1 | rg -q '^Instance ' || break + sleep 0.1 +done +if qs list 2>&1 | rg -q '^Instance '; then + fail 'shell did not stop before restart' +fi +quickshell --daemonize >/dev/null status="" for _ in $(seq 1 60); do