Add Anvil play-feel E2E for #331 visual features (#340) #515

Merged
PlasticDigits merged 1 commit from issue-340-anvil-play-feel-e2e into main 2026-06-19 12:42:39 +00:00
PlasticDigits commented 2026-06-19 11:55:52 +00:00 (Migrated from gitlab.com)

Summary

Adds Anvil Playwright play-feel E2E coverage for gap-analysis #331 visual children (#340).

  • New frontend/e2e/anvil-arena-05-play-feel.spec.ts with stable data-testid selectors for XP hero prominence, carousel navigation, next-tier level locks (#334), L1-no-celebration (#335), first-visit WYWA omission (#338 sad), and indexer-first WYWA + wallet profile level history (#338 / #336).
  • Post-buy toasts remain in anvil-arena-03-wallet-writes.spec.ts (#337).
  • Helpers: gotoCarouselDot, waitIndexerSessionSummaryActivity, seedArenaLastClosedAt in arenaE2eHelpers.ts.
  • Docs: INV-FRONTEND-340-PLAY-FEEL-E2E, frontend-content-audit.md #331 E2E rows, e2e-anvil.md §340.
  • Minor harness fixes: drop stale WarBow mount assertion (#334 policy); CRED buy warps buy-energy when run after wallet-write specs.

Relates to #340 (issue stays open until merge).

Acceptance checklist

Criterion Command / step Result
E2E covers each closed #331 visual feature with stable data-testid selectors See child→spec table below PASS
cd frontend && CI=1 npm run test:e2e -- --workers=5 e2e/anvil-arena-*.spec.ts against Anvil stack YIELDOMEGA_E2E_INDEXER=1 YIELDOMEGA_DEPLOY_NO_COOLDOWN=1 bash scripts/e2e-anvil.sh (16/16 specs; script uses workers=1 for Anvil nonce stability — see note) PASS
Sad paths: first visit no away modal; indexer unset skips indexer-first blocks anvil-arena-05-play-feel.spec.ts describe + test.skip(ANVIL_E2E_INDEXER) PASS
#331 rows in docs/testing/frontend-content-audit.md Doc diff PASS
e2e/arena.spec.ts regression cd frontend && CI=1 npm run test:e2e -- --workers=5 e2e/arena.spec.ts SKIP — 7/8 pass; one test needs non-Anvil npm run build preview (Yield Omega branding); unrelated to this MR

Child issue → spec mapping

Issue Feature Spec Result
#334 Next-tier locks + carousel anvil-arena-05-play-feel.spec.ts PASS
#335 L2+ celebration (sad: L1 no popover) anvil-arena-05-play-feel.spec.ts PASS
#336 Profile level history anvil-arena-05-play-feel.spec.ts (indexer-first) PASS
#337 Post-buy toasts anvil-arena-03-wallet-writes.spec.ts PASS
#338 While-you-were-away anvil-arena-05-play-feel.spec.ts happy + sad PASS

Workers note: playwright.config.ts pins workers: 1 when ANVIL_E2E=1 to avoid shared mock-wallet nonce races (#87). Full stack verification: YIELDOMEGA_E2E_INDEXER=1 YIELDOMEGA_DEPLOY_NO_COOLDOWN=1 bash scripts/e2e-anvil.sh.

Third-party verification

  1. bash scripts/bootstrap-cloud-postgres-native.sh (indexer-first paths)
  2. YIELDOMEGA_E2E_INDEXER=1 YIELDOMEGA_DEPLOY_NO_COOLDOWN=1 bash scripts/e2e-anvil.sh
  3. Optional targeted: cd frontend && CI=1 ANVIL_E2E=1 ANVIL_E2E_INDEXER=1 E2E_REUSE_PREVIEW=1 npx playwright test e2e/anvil-arena-05-play-feel.spec.ts
  4. Docs: bash scripts/check-doc-anchors.sh · docs/testing/invariants-and-business-logic.md (INV-FRONTEND-340-PLAY-FEEL-E2E)
## Summary Adds Anvil Playwright play-feel E2E coverage for gap-analysis #331 visual children ([#340](https://gitlab.com/PlasticDigits/yieldomega/-/issues/340)). - New `frontend/e2e/anvil-arena-05-play-feel.spec.ts` with stable `data-testid` selectors for XP hero prominence, carousel navigation, next-tier level locks (#334), L1-no-celebration (#335), first-visit WYWA omission (#338 sad), and indexer-first WYWA + wallet profile level history (#338 / #336). - Post-buy toasts remain in `anvil-arena-03-wallet-writes.spec.ts` (#337). - Helpers: `gotoCarouselDot`, `waitIndexerSessionSummaryActivity`, `seedArenaLastClosedAt` in `arenaE2eHelpers.ts`. - Docs: `INV-FRONTEND-340-PLAY-FEEL-E2E`, `frontend-content-audit.md` #331 E2E rows, `e2e-anvil.md` §340. - Minor harness fixes: drop stale WarBow mount assertion (#334 policy); CRED buy warps buy-energy when run after wallet-write specs. Relates to #340 (issue stays open until merge). ## Acceptance checklist | Criterion | Command / step | Result | |-----------|----------------|--------| | E2E covers each closed #331 visual feature with stable `data-testid` selectors | See child→spec table below | **PASS** | | `cd frontend && CI=1 npm run test:e2e -- --workers=5 e2e/anvil-arena-*.spec.ts` against Anvil stack | `YIELDOMEGA_E2E_INDEXER=1 YIELDOMEGA_DEPLOY_NO_COOLDOWN=1 bash scripts/e2e-anvil.sh` (16/16 specs; script uses workers=1 for Anvil nonce stability — see note) | **PASS** | | Sad paths: first visit no away modal; indexer unset skips indexer-first blocks | `anvil-arena-05-play-feel.spec.ts` describe + `test.skip(ANVIL_E2E_INDEXER)` | **PASS** | | #331 rows in `docs/testing/frontend-content-audit.md` | Doc diff | **PASS** | | `e2e/arena.spec.ts` regression | `cd frontend && CI=1 npm run test:e2e -- --workers=5 e2e/arena.spec.ts` | **SKIP** — 7/8 pass; one test needs non-Anvil `npm run build` preview (`Yield Omega` branding); unrelated to this MR | ### Child issue → spec mapping | Issue | Feature | Spec | Result | |-------|---------|------|--------| | #334 | Next-tier locks + carousel | `anvil-arena-05-play-feel.spec.ts` | **PASS** | | #335 | L2+ celebration (sad: L1 no popover) | `anvil-arena-05-play-feel.spec.ts` | **PASS** | | #336 | Profile level history | `anvil-arena-05-play-feel.spec.ts` (indexer-first) | **PASS** | | #337 | Post-buy toasts | `anvil-arena-03-wallet-writes.spec.ts` | **PASS** | | #338 | While-you-were-away | `anvil-arena-05-play-feel.spec.ts` happy + sad | **PASS** | **Workers note:** `playwright.config.ts` pins `workers: 1` when `ANVIL_E2E=1` to avoid shared mock-wallet nonce races ([#87](https://gitlab.com/PlasticDigits/yieldomega/-/issues/87)). Full stack verification: `YIELDOMEGA_E2E_INDEXER=1 YIELDOMEGA_DEPLOY_NO_COOLDOWN=1 bash scripts/e2e-anvil.sh`. ## Third-party verification 1. `bash scripts/bootstrap-cloud-postgres-native.sh` (indexer-first paths) 2. `YIELDOMEGA_E2E_INDEXER=1 YIELDOMEGA_DEPLOY_NO_COOLDOWN=1 bash scripts/e2e-anvil.sh` 3. Optional targeted: `cd frontend && CI=1 ANVIL_E2E=1 ANVIL_E2E_INDEXER=1 E2E_REUSE_PREVIEW=1 npx playwright test e2e/anvil-arena-05-play-feel.spec.ts` 4. Docs: `bash scripts/check-doc-anchors.sh` · `docs/testing/invariants-and-business-logic.md` (`INV-FRONTEND-340-PLAY-FEEL-E2E`)
PlasticDigits commented 2026-06-19 11:58:40 +00:00 (Migrated from gitlab.com)

Security review — MR !515

Commit reviewed: f2d5283eae044b50d1ce90ee4e56261817c7ca01
Base: bbf6bbb3f7a14a5750d8247263a0b9ef2e9796bd

Scope

Reviewed all 7 changed paths:

  • docs/testing/e2e-anvil.md, frontend-content-audit.md, invariants-and-business-logic.md (documentation only)
  • frontend/e2e/anvil-arena-01-mount.spec.ts (removed stale WarBow mount assertion)
  • frontend/e2e/anvil-arena-04-cred-buy.spec.ts (serial mode + buy-cooldown warp)
  • frontend/e2e/anvil-arena-05-play-feel.spec.ts (new play-feel coverage)
  • frontend/e2e/arenaE2eHelpers.ts (warpAnvilPastBuyCooldown, seedArenaLastClosedAt, gotoCarouselDot, waitIndexerSessionSummaryActivity)

No smart-contract, indexer service, or production frontend/src application logic changes in this diff. Prior security-review threads on this MR: none.

Analysis

Area Result
EVM / on-chain No contract or deploy-script changes
Injection (SQL/shell) Not applicable — no DB or shell execution
Authn/authz Not applicable — test harness only
SSRF waitIndexerSessionSummaryActivity and warpAnvilPastBuyCooldown call URLs from VITE_INDEXER_URL / VITE_RPC_URL (defaults 127.0.0.1) inside Playwright E2E helpers; not shipped to end users; since_ms is numeric and encodeURIComponent-encoded
XSS / CSRF No user-facing render or API handler changes
Secret leakage No credentials or keys introduced
Supply chain No dependency manifest changes

Test helpers operate against local Anvil/indexer fixtures under ANVIL_E2E=1 / YIELDOMEGA_E2E_INDEXER=1 gates. localStorage seeding uses the existing ARENA_LAST_CLOSED_AT_KEY constant for WYWA assertions only.

Outcome

FINDINGS: 0 medium, high, or critical.

Security review: no medium+ findings on this diff.

No inline threads (nothing to flag).

## Security review — MR !515 **Commit reviewed:** `f2d5283eae044b50d1ce90ee4e56261817c7ca01` **Base:** `bbf6bbb3f7a14a5750d8247263a0b9ef2e9796bd` ### Scope Reviewed all 7 changed paths: - `docs/testing/e2e-anvil.md`, `frontend-content-audit.md`, `invariants-and-business-logic.md` (documentation only) - `frontend/e2e/anvil-arena-01-mount.spec.ts` (removed stale WarBow mount assertion) - `frontend/e2e/anvil-arena-04-cred-buy.spec.ts` (serial mode + buy-cooldown warp) - `frontend/e2e/anvil-arena-05-play-feel.spec.ts` (new play-feel coverage) - `frontend/e2e/arenaE2eHelpers.ts` (`warpAnvilPastBuyCooldown`, `seedArenaLastClosedAt`, `gotoCarouselDot`, `waitIndexerSessionSummaryActivity`) No smart-contract, indexer service, or production `frontend/src` application logic changes in this diff. Prior security-review threads on this MR: none. ### Analysis | Area | Result | |------|--------| | EVM / on-chain | No contract or deploy-script changes | | Injection (SQL/shell) | Not applicable — no DB or shell execution | | Authn/authz | Not applicable — test harness only | | SSRF | `waitIndexerSessionSummaryActivity` and `warpAnvilPastBuyCooldown` call URLs from `VITE_INDEXER_URL` / `VITE_RPC_URL` (defaults `127.0.0.1`) inside Playwright E2E helpers; not shipped to end users; `since_ms` is numeric and `encodeURIComponent`-encoded | | XSS / CSRF | No user-facing render or API handler changes | | Secret leakage | No credentials or keys introduced | | Supply chain | No dependency manifest changes | Test helpers operate against local Anvil/indexer fixtures under `ANVIL_E2E=1` / `YIELDOMEGA_E2E_INDEXER=1` gates. `localStorage` seeding uses the existing `ARENA_LAST_CLOSED_AT_KEY` constant for WYWA assertions only. ### Outcome **FINDINGS: 0** medium, high, or critical. Security review: **no medium+ findings** on this diff. No inline threads (nothing to flag).
PlasticDigits (Migrated from gitlab.com) merged commit 8f69524756 into main 2026-06-19 12:42:39 +00:00
PlasticDigits commented 2026-06-19 12:42:40 +00:00 (Migrated from gitlab.com)

mentioned in commit 8f69524756

mentioned in commit 8f695247562c29822c912a83052bfa5d01101f56
Sign in to join this conversation.
No reviewers
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
code/yieldomega!515
No description provided.