Skip to content

test: split stack-backed e2e into a serial project and gate CI jobs by path - #6472

Draft
kanadgupta wants to merge 3 commits into
developfrom
kanad-claude/e2e-stack-split
Draft

test: split stack-backed e2e into a serial project and gate CI jobs by path#6472
kanadgupta wants to merge 3 commits into
developfrom
kanad-claude/e2e-stack-split

Conversation

@kanadgupta

Copy link
Copy Markdown
Member

Summary

First of three PRs from the test-execution plan in docs/superpowers/plans/2026-09-04-test-execution-topology.md. Everything here works on Vitest 4; the Vitest 5 upgrade (#6457) and the root-run topology follow separately.

Stack-backed e2e becomes a serial sub-kind; everything else runs in parallel. Every e2e project ran files strictly serially, a setting from the first architecture commit that contradicts the flake policy in AGENTS.md. In the last develop run the 13 e2e files that start a local stack accounted for about 72% of e2e time while 58 stackless files queued behind them. Those 13 files now carry the *.stack.e2e.test.ts suffix and run one at a time in an e2e-stack project; plain *.e2e.test.ts files keep the e2e project with default file parallelism. Vitest schedules the serial group after the parallel one within a run, so no custom scheduling is involved. The renames have no content changes.

CI test jobs are gated on the paths a PR touches. About a third of recent PRs were Go-only or docs-only and still ran the full TypeScript suite. A paths-filter job classifies the change: docs or release-notes only skips every test job; Go-only skips unit and integration but keeps e2e, which shells out to the Go sidecar; anything under .github or a TypeScript workspace runs everything. The code-quality job is never gated, and both summary jobs fail unless the gate succeeded, so a broken gate cannot produce a false green. turbo --affected was rejected because Turbo's package graph does not know the CLI depends on the Go sidecar, and a gate that installs dependencies would delay every test job by over a minute.

ADR 0024 and the plan. The ADR records the whole direction, including the vocabulary (test kind, stack-backed versus stackless, test project, standalone versus root run) and the rejected alternatives, so reviewers of the later PRs can see the rationale. The plan carries the measured baseline and the three-PR sequence.

Expected effect: the worst e2e shard's test step drops from about 7.9 minutes toward 5 minutes even under today's per-package hash sharding; balancing across packages is PR C's job.

🤖 Generated with Claude Code

kanadgupta and others added 3 commits September 4, 2026 15:00
…arallel

Every e2e project ran files strictly serially, a setting from the initial
architecture commit that contradicts the flake policy in AGENTS.md and
left the CLI's 32 stackless e2e files queueing behind the 10 that start a
local stack. The stack-backed files are 72% of e2e time, so this split
is the main lever on the worst CI shard.

E2e files that start a local Supabase stack or run a Docker container now
carry the *.stack.e2e.test.ts suffix and belong to a serial e2e-stack
project. Plain *.e2e.test.ts files keep the e2e project with Vitest's
default file parallelism. packages/stack has only stack-backed e2e, so
its e2e project becomes e2e-stack. Package test:e2e:run scripts select
both projects. Thirteen files are renamed with no content changes.

Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
About a third of recent PRs were Go-only or docs-only and still ran the
full TypeScript test suite. A paths-filter job now classifies the change:
docs or release-notes only skips every test job; Go-only skips unit and
integration but keeps e2e, which shells out to the Go sidecar; anything
under .github or a TypeScript workspace runs everything. The code-quality
job is never gated. Both summary jobs fail unless the gate job succeeded,
so a broken gate cannot produce a false green.

Turbo's --affected was considered and rejected: its package graph does not
know the CLI depends on the Go sidecar (that edge exists only in the task
graph), and a gate job that installs dependencies would add over a minute
before any test job could start.

Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
Records the agreed direction for how tests run: root Vitest runs as the
unit of execution, stack-backed e2e as a suffix-marked serial sub-kind,
weight-class sharding, and Turbo reduced to the build graph. The ADR
carries the vocabulary for these concepts; the dated plan carries the
measured baseline and the three-PR sequence this PR starts.

Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
@kanadgupta kanadgupta added the run-ci Run full develop CI (tests + preview pkgs) on drafts and non-develop PRs. label Sep 4, 2026
@github-actions

github-actions Bot commented Sep 4, 2026

Copy link
Copy Markdown
Contributor

Supabase CLI preview

npx --yes https://pkg.pr.new/supabase/cli/supabase@ccb2a6f539b077663b270966378dc920be432864

Preview package for commit ccb2a6f.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

run-ci Run full develop CI (tests + preview pkgs) on drafts and non-develop PRs.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant