mirror of
https://github.com/mauriceboe/TREK.git
synced 2026-11-20 11:06:06 +00:00
ci(test): give the e2e container a compiler on a node_modules cache miss
better-sqlite3 compiles on install, and the Playwright container has no make or g++, so the first e2e run of a lockfile failed in npm ci. The setup action now installs both when they are missing, before npm ci; a cache hit skips the step.
This commit is contained in:
@@ -94,6 +94,16 @@ runs:
|
||||
SCOPE: ${{ inputs.scope }}
|
||||
run: |
|
||||
set -euo pipefail
|
||||
# better-sqlite3 ships no prebuilt binary and compiles on install. The
|
||||
# hosted runners carry a compiler; the Playwright container of the e2e
|
||||
# jobs does not, so on a cache miss there it gets one first. A hit,
|
||||
# the usual case once a push to dev has saved the container's key,
|
||||
# never reaches this step.
|
||||
if ! command -v make >/dev/null || ! command -v g++ >/dev/null; then
|
||||
export DEBIAN_FRONTEND=noninteractive
|
||||
timeout 300 apt-get update -qq
|
||||
timeout 300 apt-get install -y -qq --no-install-recommends make g++
|
||||
fi
|
||||
case "$SCOPE" in
|
||||
full) npm ci ;;
|
||||
# The scoped install keeps @testing-library/dom (a peer of
|
||||
|
||||
Reference in New Issue
Block a user