Skip to content

test(examples): VRT automation for stress-tv & viewport-memory; fix shader name#81

Merged
chiefcll merged 2 commits into
mainfrom
feat/vrt-stress-tv-viewport-memory
Jun 9, 2026
Merged

test(examples): VRT automation for stress-tv & viewport-memory; fix shader name#81
chiefcll merged 2 commits into
mainfrom
feat/vrt-stress-tv-viewport-memory

Conversation

@chiefcll

@chiefcll chiefcll commented Jun 9, 2026

Copy link
Copy Markdown
Contributor

What

Brings two examples into the visual-regression suite and fixes a latent shader-name bug they'd otherwise certify.

VRT automation

Adds an automation export to stress-tv and viewport-memory. Each runs test(settings), waits for the renderer to go idle (waitUntilIdle), then snapshot()s the stable final frame. Neither was covered before — the whole dense-grid / stress family had zero visual coverage.

Shader-name fix

Several examples called createShader('RoundedRectangle', …), but the registered key is 'Rounded' (examples/common/installShaders.ts). The wrong name silently fell back to the default shader — so "rounded" rectangles rendered with square corners, and circles rendered as squares. Adding a VRT for viewport-memory without this fix would have certified the bug. Corrected across all occurrences:

  • viewport-memory.ts (4×) — its red/blue/yellow circles and green rounded rects
  • mount-pivot.ts (2×)
  • scaling-animations.ts
  • text-events.ts

None of these are currently in VRT, so no existing certified snapshot changes.

Verified in-browser

  • viewport-memory now renders true circles and rounded corners, no ShaderType not found warning (before: squares).
  • stress-tv renders unchanged after its default function was renamed to test (so the new automation export can drive it); interactive remote controls untouched.

Notes for reviewer

  • CI snapshots to be captured manually (pnpm test:visual:update-ci, Docker) — as agreed.
  • RoundedRectangleRounded is the same latent bug originally flagged for viewport-memory; fixed everywhere it appears in the examples while here.

🤖 Generated with Claude Code

chiefcll and others added 2 commits June 8, 2026 23:13
…ix shader name

Adds an `automation` export to stress-tv and viewport-memory so they run in the
visual-regression suite (each waits for the renderer to go idle, then snapshots
the stable final frame). Neither was covered before — the whole dense-grid /
stress family had no visual coverage, and nothing rendered enough quads to
exercise the index-buffer path end to end.

Also fixes a latent bug these snapshots would otherwise have certified: several
examples called `createShader('RoundedRectangle', …)`, but the registered key is
`'Rounded'` (see examples/common/installShaders.ts). The wrong name silently
fell back to the default shader, so "rounded" rectangles rendered with square
corners (and circles rendered as squares). Corrected across all occurrences:
viewport-memory, mount-pivot, scaling-animations, text-events.

stress-tv's default function is renamed to `test` so the new `automation`
export can drive it; interactive behaviour is unchanged.

Verified in the browser: viewport-memory now renders true circles and rounded
corners with no "ShaderType not found" warning; stress-tv renders unchanged.

CI snapshots to be captured manually.

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

Captured in the Linux `ci` Docker environment (visual-regression:latest,
RUNTIME_ENV=ci) so they match the GitHub Actions baseline. 1280x720 PNGs.

- stress-tv-1.png: tier-4 grid (rounded cards + images + SDF title/subtitle)
- viewport-memory-1.png: rounded shapes — confirms the RoundedRectangle->Rounded
  fix (true circles + rounded corners, previously squares)

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
@chiefcll chiefcll merged commit 73a038a into main Jun 9, 2026
1 check passed
@chiefcll chiefcll deleted the feat/vrt-stress-tv-viewport-memory branch June 9, 2026 03:36
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant