test(e2e): aggregate-all-missing env vars in a preflight setup project #98

Merged
nrupard merged 1 commit from fix/e2e-runner-toolcache into main 2026-06-05 17:07:04 +02:00
Owner

env.ts threw at the FIRST missing required var, so a CI run with five unset Forgejo secrets only ever reported Missing required env var E2E_EMAIL per attempt. The operator had to fix one, rerun, see the next missing one, fix that, rerun, and so on - five trips minimum.

Add preflightRequiredEnv() in lib/env.ts that walks the full required-var list and throws a single error listing every gap with a one-line purpose for each. Wire it through a new preflight setup project (tests/preflight.setup.ts) that setup and auth-ui both depend on; api already depends on setup so it inherits the gate transitively.

auth-ui was previously dependency-free, so on a misconfigured CI it raced past preflight straight into a SPA-form failure deep in the test. The new dependency makes its failure mode match the rest: one clean error from preflight, not three different exceptions across three projects.

#PMS-140

env.ts threw at the FIRST missing required var, so a CI run with five unset Forgejo secrets only ever reported `Missing required env var E2E_EMAIL` per attempt. The operator had to fix one, rerun, see the next missing one, fix that, rerun, and so on - five trips minimum. Add `preflightRequiredEnv()` in lib/env.ts that walks the full required-var list and throws a single error listing every gap with a one-line purpose for each. Wire it through a new `preflight` setup project (tests/preflight.setup.ts) that `setup` and `auth-ui` both depend on; `api` already depends on `setup` so it inherits the gate transitively. `auth-ui` was previously dependency-free, so on a misconfigured CI it raced past preflight straight into a SPA-form failure deep in the test. The new dependency makes its failure mode match the rest: one clean error from preflight, not three different exceptions across three projects. #PMS-140
test(e2e): aggregate-all-missing env vars in a preflight setup project
All checks were successful
Create release / Create release from merged PR (pull_request) Has been skipped
Check / fmt + clippy + compile + tests (pull_request) Successful in 1m37s
104ed55872
env.ts threw at the FIRST missing required var, so a CI run with five unset Forgejo secrets only ever reported `Missing required env var E2E_EMAIL` per attempt. The operator had to fix one, rerun, see the next missing one, fix that, rerun, and so on - five trips minimum.

Add `preflightRequiredEnv()` in lib/env.ts that walks the full required-var list and throws a single error listing every gap with a one-line purpose for each. Wire it through a new `preflight` setup project (tests/preflight.setup.ts) that `setup` and `auth-ui` both depend on; `api` already depends on `setup` so it inherits the gate transitively.

`auth-ui` was previously dependency-free, so on a misconfigured CI it raced past preflight straight into a SPA-form failure deep in the test. The new dependency makes its failure mode match the rest: one clean error from preflight, not three different exceptions across three projects.

#PMS-140
nrupard deleted branch fix/e2e-runner-toolcache 2026-06-05 17:07:04 +02:00
Sign in to join this conversation.
No reviewers
No labels
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set

Reference
psa-systems/mokosh-server!98
No description provided.