Skip to content

test(e2e): centralize gamemode knowledge behind a seam module - #814

Open
garrappachc wants to merge 2 commits into
masterfrom
refactor/e2e-groundwork
Open

garrappachc wants to merge 2 commits into
masterfrom
refactor/e2e-groundwork

Conversation

@garrappachc

@garrappachc garrappachc commented Aug 27, 2026

Copy link
Copy Markdown
Member

📚 Multi-gamemode 5.0.0 PR stack — merge bottom-up:


First PR of the multi-gamemode (5.0.0) stack — pure groundwork, no behavior change.

Why

The e2e suite scatters per-gamemode facts (slot layout, player count, @6v6/@9v9 grep tag, queue path) across queue-slots.ts, the page objects, and the specs. Before the real multi-gamemode migration (later in the stack) converts the suite from "one gamemode per CI run via QUEUE_CONFIG" to "navigate /6v6, /9v9… within one instance", it helps to gather those facts behind a single seam so that migration only has to widen the seam instead of touching every spec.

What

  • New tests/gamemodes.ts — one source of truth: per-gamemode classes, path, tag, plus currentGamemode(), queueSlots(), getPlayerCount().
  • tests/queue-slots.ts becomes a thin re-export shim so specs are untouched.
  • QueuePage.goto() navigates via gamemodes[currentGamemode()].path (still / today).

Behavior is identical: still QUEUE_CONFIG-driven, every queue still at /, CI matrix and specs unchanged. Verified the seam emits the exact same slot list/count for both 6v6 (12) and 9v9 (18).

Also lands the stack's design docs: CONTEXT.md (glossary) and docs/adr/0001-global-game-numbering-with-merge-remap.md.

garrappachc and others added 2 commits August 27, 2026 11:23
Groundwork for the 5.0.0 multi-gamemode stack: a domain glossary and the
ADR recording why game numbers stay a single global sequence with a merge
remap table rather than a per-gamemode composite key.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
Move the per-gamemode facts (slot layout, player count, grep tag, queue
path) out of queue-slots.ts into a single tests/gamemodes.ts. Behavior is
unchanged — still QUEUE_CONFIG-driven, every queue still served at `/` — so
that the coming multi-gamemode migration only widens this seam (env selection
-> per-path, distinct paths per gamemode) instead of touching every spec.
queue-slots.ts stays as a thin re-export shim to keep specs untouched.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
@github-actions

Copy link
Copy Markdown
Contributor

Playwright test results

passed  246 passed

Details

stats  246 tests across 47 suites
duration  12 minutes, 47 seconds
commit  5af47c5

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

Labels

None yet

Development

Successfully merging this pull request may close these issues.

1 participant