Skip to content

tests: split the route overflow e2e matrix to avoid suite-level timeout flakes - #470

Merged
Ducksss merged 1 commit into
devfrom
tests/split-route-overflow-matrix
Aug 13, 2026
Merged

Ducksss merged 1 commit into
devfrom
tests/split-route-overflow-matrix

Conversation

@Ducksss

@Ducksss Ducksss commented Aug 11, 2026 •

Copy link
Copy Markdown
Owner

Closes #108. Ports @harshvardhan60792's work from #463 onto dev (original authorship preserved on the commit).

Why this is a port rather than a retarget

#463 was opened against main. Retargeting it to dev is not safe here: main and dev diverged through squash promotes, so merge-base(pr-463, dev) resolves all the way back to ddd8eb08 (v1.2.0). A retargeted #463 would have rendered as 802 files / +65,927 lines rather than the one file it actually changes. Cherry-picking onto dev keeps the diff honest at 1 file, +71/-64.

What it does

The no-horizontal-overflow check was one test performing ~70 sequential navigations. Any single slow route could push the whole matrix past the 180s per-test timeout even though every route passed in isolation, and a failure named only the matrix, never the route.

This registers one test per route instead. Coverage is unchanged — same routes, same three assertions (title, H1, no horizontal overflow), same /components/preview/** subframe blocking that #249 added.

Two things worth noting for review:

workers: 1 means the split trades a small amount of wall clock (a fresh browser context, and therefore a cold HTTP cache, per route) for removing the aggregate-timeout failure class entirely. On a loopback production server that per-route overhead is small; the release gate on this PR is the real measurement.

Verification

prettier --check and eslint pass locally on the changed file. The full release gate has never actually run against this change — #463 targeted main, so pr-gate never triggered on it and only Vercel and CodeRabbit reported. This PR puts it through the real gate for the first time.

Summary by CodeRabbit

  • Tests
    • Expanded end-to-end route coverage with independent tests for each route.
    • Added validation for page titles, headings, font loading, and horizontal overflow.
    • Improved handling of component previews and included both production and development routes.

The route-overflow e2e test walked ~24 routes sequentially in one Playwright test, so one slow navigation could push the whole matrix over the per-test timeout even though each route passed alone; splitting it into one test per route (named by path) keeps every route covered while isolating failures and timeouts to the specific route.
Copilot AI lite review requested due to automatic review settings August 11, 2026 14:25
@vercel

vercel Bot commented Aug 11, 2026 •

Copy link
Copy Markdown

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Actions Updated (UTC)
payload-components Ready Ready Preview Aug 11, 2026 2:31pm
payload-components-97bf Ready Ready Preview Aug 11, 2026 2:31pm

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Copilot was unable to review this pull request because the user who requested the review has reached their quota limit.

@coderabbitai

coderabbitai Bot commented Aug 11, 2026 •

Copy link
Copy Markdown

Review Change Stack

No actionable comments were generated in the recent review. 🎉

ℹ️ Recent review info
⚙️ Run configuration

Configuration used: Path: .coderabbit.yaml

Review profile: CHILL

Plan: Pro Plus

Run ID: 9356d930-e49c-4e03-8b0e-43ed096cc9e7

📥 Commits

Reviewing files that changed from the base of the PR and between 7138a07 and 8da4e70.

📒 Files selected for processing (1)
  • tests/e2e/frontend.e2e.spec.ts

📝 Walkthrough

Walkthrough

The frontend route smoke test now creates one Playwright test per route. Production and development modes use separate component coverage rules. Each test preserves title, heading, font, and horizontal-overflow checks with route-specific failure reporting.

Changes

Frontend route smoke coverage

Layer / File(s) Summary
Isolated route test matrix
tests/e2e/frontend.e2e.spec.ts
The sequential route loop is replaced with independent tests. Production checks all component entries, while development checks one representative per category. Each test aborts preview subframes and validates the route title, visible H1, font readiness, and absence of horizontal overflow.

Estimated code review effort: 2 (Simple) | ~10 minutes

Possibly related PRs

🚥 Pre-merge checks | ✅ 5
✅ Passed checks (5 passed)
Check name Status Explanation
Title check ✅ Passed The title clearly describes splitting the route overflow end-to-end test to prevent suite-level timeout flakes.
Description check ✅ Passed The description explains the change, rationale, scope, and verification status, but it omits the template's Registry Checklist and Notes sections.
Linked Issues check ✅ Passed The change preserves route coverage and assertions, identifies failures by route, avoids timeout increases, and remains compatible with the stated scope.
Out of Scope Changes check ✅ Passed The changes are limited to the relevant frontend end-to-end test and address the linked issue without unrelated layout or test changes.
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check.
✨ Finishing Touches
📝 Generate docstrings
  • Create stacked PR
  • Commit on current branch
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch tests/split-route-overflow-matrix

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands.

This branch was successfully deployed

2 active deployments
Preview – payload-components-97bf — 8da4e700 Deployed Aug 11, 2026 by vercel[bot]
Preview – payload-components — 8da4e700 Deployed Aug 11, 2026 by vercel[bot]
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.

3 participants