smoketest: wait for Superpanel's app to quit before opening it again

Opened again while the last one was still quitting, Launch Services
failed with -600 now and then.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
David Young
2026-11-29 14:52:30 -07:00
co-authored by Claude Opus 5.5
parent ad97e68db1
commit 3282857a9f
+9 -1
View File
@@ -4,8 +4,16 @@ TIER=quick
source "$CONNECTOR/configure.d/10-core.sh"
# The app opens its page and quits. Opened again while the last one is still
# quitting, Launch Services can fail with -600 (no such process), so this
# waits for it to be gone and tries once more.
superpanel_opens() {
open -g -W "$SUPERPANEL_APP"
local i
for i in 1 2 3 4 5 6 7 8 9 10; do
pgrep -f "$SUPERPANEL_APP/Contents/MacOS/" > /dev/null || break
sleep 1
done
open -g -W "$SUPERPANEL_APP" 2> /dev/null || { sleep 3; open -g -W "$SUPERPANEL_APP"; }
}
scenario() {