Skip to content

test(landing,int): tighten the wall ceiling and stop pinning prettier's line breaks - #413

Merged
Ducksss merged 1 commit into
devfrom
claude/wall-ceiling-and-assertion-hardening
Jul 30, 2026
Merged

Ducksss merged 1 commit into
devfrom
claude/wall-ceiling-and-assertion-hardening

Conversation

@Ducksss

@Ducksss Ducksss commented Jul 29, 2026

Copy link
Copy Markdown
Owner

Two follow-ups from the wall and prettier work. Both are about assertions that were passing for the wrong reason. Test-only, no behaviour change.

The wall fit guard had a blind band

The ceiling was 60px against a measured worst case of 44px, so 44–60 was room for a card to quietly lose a line and still go green. That isn't hypothetical: TestimonialsBentoDemo changed height in the very promote that shipped the guard, so twin content demonstrably drifts.

Now 50px — still clear of an ordinary copy edit, but with nowhere for a regression to hide. Comment records the intent: if a legitimate content change trips it, move the frame, not the ceiling.

~197 assertions pin prettier's line breaks

fumadocs-site.int.spec.ts asserts exact substrings of source files, and prettier owns the line breaks in every one of those files. So any pin spanning more than a single token is partly a pin on formatting — which is exactly what broke during the reflow: the twitter literal in blog/[slug]/page.tsx crossed 100 columns, prettier split it, and the assertion failed while the metadata it guards was completely untouched.

The whitespace-collapsing helper added for that case is now file-scoped and documented, and applied to the three remaining pins that span a brace, an arrow, or a ternary:

pin file it reads
import type { HeroBasicBlock as HeroBasicBlockData } hero component source
themeSwitch={{ enabled: false }} docs layout
rel={item.label === 'GitHub' ? 'noreferrer' : undefined} SiteHeader

I checked all 19 candidates that looked fragile; the rest either target .mdx/docs content (prettier-ignored, so they can't wrap) or are bare identifiers, which cannot wrap either. Those stay matched raw.

Verification

…'s line breaks

Two follow-ups from the wall and prettier work, both about assertions that pass
for the wrong reason.

The wall fit guard allowed 60px of overrun against a measured worst case of 44px.
That 44-60 band was room for a card to quietly lose a line and still go green, and
twin content does drift — TestimonialsBentoDemo changed height in the same promote
that shipped the guard. The ceiling is now 50px: still clear of an ordinary copy
edit, but no longer a place a regression can hide. If a legitimate content change
trips it, the frame should move, not the ceiling.

fumadocs-site.int.spec.ts pins ~197 exact substrings of source files, and prettier
owns the line breaks in every one of those files, so any pin spanning more than a
single token is partly a pin on formatting. That is what broke here: the twitter
literal in blog/[slug]/page.tsx crossed 100 columns, prettier split it, and the
assertion failed while the metadata it guards was untouched. The whitespace-
collapsing helper introduced for that case is now file-scoped and documented, and
applied to the three remaining pins that span a brace, an arrow or a ternary
(heroComponent's payload-types import, docsLayout's themeSwitch, siteHeader's rel
ternary). Bare identifiers cannot wrap and stay matched raw.

No behaviour change; both are test-only. Verified: 4/4 wall guard tests at the new
ceiling, 379/380 int tests, eslint / tsc / format:check clean. The int run also
confirms vite 8.1.5 is healthy on dev now that #412 dropped the tsconfig react
types path that used to block it.

Co-Authored-By: Claude Opus 5 <[email protected]>
Copilot AI review requested due to automatic review settings July 29, 2026 16:59

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.

@vercel

vercel Bot commented Jul 29, 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, Comment Jul 29, 2026 5:05pm
payload-components-97bf Ready Ready Preview, Comment Jul 29, 2026 5:05pm

@coderabbitai

coderabbitai Bot commented Jul 29, 2026

Copy link
Copy Markdown

Warning

Review limit reached

@Ducksss, you've reached your PR review limit, so we couldn't start this review.

Next review available in: 53 minutes

Enable usage-based reviews in Billing to review now. Otherwise, wait until the next included review is available.
You're only billed for reviews past your plan's rate limits ($0.25/file).

How can I continue?

After more reviews become available, a review can be triggered using the @coderabbitai review command as a PR comment. Alternatively, push new commits to this PR.

To avoid repeated limits, reduce automatic review volume by pausing incremental auto-reviews earlier, using label-based review opt-in, excluding WIP or generated PR titles, or requesting reviews manually when the PR is ready. If your team needs uninterrupted high-volume reviews, an organization admin can enable usage-based reviews.

How do review limits work?

CodeRabbit enforces per-developer PR review limits for each organization. Most developers receive the normal plan review availability.

For paid Pro and Pro+ PR reviews, CodeRabbit uses adaptive limits for sustained high-volume activity. When a developer's recent PR review activity reaches the 95th percentile or higher among CodeRabbit users, additional reviews become available more gradually as earlier reviews age out of the rolling window.

Please refer docs for additional details.

Review details
⚙️ Run configuration

Configuration used: Path: .coderabbit.yaml

Review profile: CHILL

Plan: Pro Plus

Run ID: 2e21842c-99e1-4b11-892d-3db7b7adb293

📥 Commits

Reviewing files that changed from the base of the PR and between aa3b6a9 and 99f307a.

📒 Files selected for processing (2)
  • tests/e2e/frontend.e2e.spec.ts
  • tests/int/fumadocs-site.int.spec.ts

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.

@Ducksss
Ducksss merged commit 60939c7 into dev Jul 30, 2026
12 checks passed
Ducksss added a commit that referenced this pull request Jul 30, 2026
…dening, dependency refresh (#416)

Brings main level with dev ahead of publishing 1.2.1.

- wall fit guard tightened from 60px to 50px, and the fumadocs int spec no longer
  pins prettier's line breaks (#413)
- CodeRabbit findings from the last five days closed (#411)
- tsconfig drops the redundant react types path that blocked every vite 8 bump
  (#412), unblocking vite 8.1.5; dependency refresh for lucide-react, fumadocs and
  the test tooling (#365, #366, #367)
- shadcn bumped to 4.15.0 with the CLI pin single-sourced, so a version bump no
  longer has to be written in four places (#401)

Tree is identical to dev by construction: branched from dev, reparented onto main,
so the diff is exactly the main..dev delta with no squash-divergence conflicts.
Ducksss added a commit that referenced this pull request Aug 2, 2026
…le test claims (#418)

Closes the three CodeRabbit findings on promote #416. Each was verified against
the source before changing anything.

1. src/lib/consent.ts — GA cookie withdrawal missed the registrable domain on
   multi-label public suffixes. `labels.slice(-2)` sends `www.example.co.uk` to
   `co.uk` and never `example.co.uk`, so a cookie on the real registrable domain
   survived withdrawal. Which parent IS registrable needs a public-suffix list
   the browser does not expose, so enumerate every parent instead of assuming
   two labels — matching the function's existing "the misses are inert" design.
   The bare TLD is skipped since no host can set a cookie there.

   Latent rather than live: for `www.payload-components.xyz`, `slice(-2)` already
   yielded `payload-components.xyz`, the correct domain. It bit only hosts under
   a two-part suffix. Verified the new enumeration across host shapes —
   `www.example.co.uk` now reaches `example.co.uk`, `a.b.example.com` reaches
   both parents, `payload-components.xyz` and `localhost` are unchanged.

   No test pinned the old behaviour: consent.e2e sets its cookies with no domain,
   which the pre-existing `''` entry covers, and the change is purely additive.

2. tests/e2e/frontend.e2e.spec.ts — a comment still called the overrun ceiling
   "deliberately loose 60px" after #413 tightened it to 50px. The neighbouring
   line 245 reference is deliberate history ("It was 60px, but…") and is left
   alone; only the claim about the current value was wrong.

3. tests/int/painted-contrast.int.spec.ts — the fixture carried
   `'.stat-value (no glyph pixels)'`, but the producer pushes the bare selector
   (painted-contrast.ts:572) and the label supplies the reason. The two lists
   genuinely differ in shape — `unresolvedSelectors` IS pushed pre-suffixed
   (:229, :233), so that fixture is correct and untouched — and the asymmetry is
   now written down so the next edit does not "fix" the wrong one.

   Scope note: this makes the fixture faithful to what the producer emits. It
   does not couple the two — the spec imports only `formatPaintedContrastReport`
   and never calls `measurePaintedTextContrast`, which needs a browser.

Local: lint, format:check, tsc --noEmit, test:int (32 files / 379 tests) green.
The consent behaviour itself is covered by consent.e2e in release-gate.

Co-authored-by: Claude Opus 5 <[email protected]>
@Ducksss
Ducksss deleted the claude/wall-ceiling-and-assertion-hardening branch August 3, 2026 08:49

This branch was successfully deployed

2 active deployments
Preview – payload-components-97bf — 99f307a7 Deployed Jul 29, 2026 by vercel[bot]
Preview – payload-components — 99f307a7 Deployed Jul 29, 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.

2 participants