chore(ci): check:all names each browser suite PASSED, SKIPPED or NOT RUN

A failing stage prints FAILED with its name and exits non-zero; e2e:shell is
reported NOT RUN (it needs the isolated stack); both suites keep their own
commands.
This commit is contained in:
bchanot committed 2026-10-26 01:02:54 +01:00
1 parent ba3a51e1b8
commit d7845b7339
2 files changed
+23 -8

No files matched your search

+10 -2
View File
@@ -7,14 +7,18 @@
# `pnpm db:test` is the real-stack complement after a change under supabase/. The browser
# suite runs when the Chromium of the pinned Playwright is installed, else it is reported
# SKIPPED with the reason (docs/development/BROWSER_TESTS.md); `pnpm e2e:shell` needs the
# isolated stack and stays a separate run.
# isolated stack and stays a separate run, reported NOT RUN. The last lines state each
# browser suite: PASSED, SKIPPED (environment missing) or NOT RUN; a failure is FAILED.
set -euo pipefail
cd "$(dirname "$0")/.."
stage() {
current_stage="$1"
printf '\n== %s (%s)\n' "$1" "$(date +%H:%M:%S)"
}
# A failing stage stops the run and is named as FAILED, never turned into a warning.
trap 'echo "== FAILED: $current_stage" >&2' ERR
stage "rust: fmt, clippy, tests, ts-rs export, cargo-deny (native toolchain)"
bash scripts/rust-check.sh
@@ -38,8 +42,10 @@ stage "browser: Chromium UI suite (pnpm e2e:ui), desktop and 375 px, axe"
chromium="$(cd apps/app && node -e "console.log(require('@playwright/test').chromium.executablePath())")"
if [ -x "$chromium" ]; then
pnpm e2e:ui
browser_ui="PASSED"
else
echo "== SKIPPED: no Chromium for the pinned Playwright at $chromium"
browser_ui="SKIPPED: no Chromium for the pinned Playwright at $chromium"
echo "== $browser_ui"
echo " install it without sudo: pnpm --filter @faunosteo/app exec playwright install chromium"
fi
stage "docker: application image"
@@ -51,3 +57,5 @@ pnpm worker:image
docker run --rm --read-only --cap-drop ALL --security-opt no-new-privileges:true \
faunosteo_worker:dev run --check
stage "all checks passed"
echo " browser e2e:ui $browser_ui"
echo " browser e2e:shell NOT RUN by check:all: it needs the isolated stack (pnpm db:sandbox up fresh, then pnpm e2e:shell)"