Skip to content

test(smoke): match fingerprinted featured-topics carousel markup (#1604) - #1616

Merged
jung-thomas merged 1 commit into
mainfrom
worktree-fix-featured-topics-smoke-fingerprint
Aug 11, 2026
Merged

test(smoke): match fingerprinted featured-topics carousel markup (#1604)#1616
jung-thomas merged 1 commit into
mainfrom
worktree-fix-featured-topics-smoke-fingerprint

Conversation

@jung-thomas

Copy link
Copy Markdown
Contributor

Problem

Follow-up to #1613. Once the island-manifest pipeline was fixed, test/smoke/featured-topics.smoke.test.js began failing on every deploy — not a regression: the carousel renders correctly, the test just checks stale markers.

  • Homepage-mount assertion looked for id="featured-topics-carousel", but the island's real SSR attribute is data-app="featured-topics-carousel" (see hugo-apps/src/featured-topics-carousel/main.tsquerySelectorAll('[data-app="featured-topics-carousel"]')).
  • Both the mount fallback and the bundle-200 test assumed the unhashed /js/featured-topics-carousel.js path, but Content-hash the Vite JS island bundles (stale-edge risk on ~50 /js/*.js) #1604 content-hashes it to /js/featured-topics-carousel-<hash>.js.

Fix

  • Mount check now matches data-app="featured-topics-carousel" with a hash-tolerant script-tag fallback.
  • Bundle-200 check resolves the real (hashed) URL from the homepage HTML instead of hardcoding the unhashed path.

Verification

Ran against live DEV (SMOKE_BASE_URL/SMOKE_SRV_URL): 7/7 pass. Confirmed the live homepage serves the fingerprinted /js/featured-topics-carousel-D2NOJUxn.js and the SSR <section data-app=featured-topics-carousel> mount.

The featured-topics homepage-mount smoke test keyed on id="featured-topics-carousel"
(the real SSR attribute is data-app=) OR the bare unhashed /js/x.js literal. #1604
content-hashes the island bundle (/js/featured-topics-carousel-<hash>.js), so both
markers stopped matching and the smoke gate failed on every deploy once the manifest
pipeline was fixed (PR #1613) — even though the carousel renders correctly (SSR
section + hashed script both present, verified live on DEV).

- mount check now matches data-app="featured-topics-carousel" (+ hash-tolerant script fallback)
- bundle-200 check resolves the real hashed URL from the homepage HTML instead of
  assuming the unhashed path

Verified: 7/7 pass against live DEV.
@jung-thomas
jung-thomas merged commit 74b04bd into main Aug 11, 2026
2 of 3 checks passed
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