镜像站点 · 本页由第三方 GitHub 只读镜像提供,非 GitHub 官方站点,不接受任何登录或凭据输入。前往 github.com
Skip to content

test: delete styling, markup and call-count trivia tests - #1255

Merged
wesbillman merged 2 commits into
mainfrom
carl/test-trivia-cuts
Oct 16, 2026
Merged

wesbillman merged 2 commits into
mainfrom
carl/test-trivia-cuts

Conversation

@wesbillman

@wesbillman wesbillman commented Oct 16, 2026 •

Copy link
Copy Markdown
Collaborator

Phase 1 of slimming the test suite. Tests are 333k lines against 248k of production code, and Playwright takes 81% of CI runner time. This PR removes tests that only freeze presentation or implementation detail:

  • paint values: radius, RGB, margins, fonts
  • class, data-attribute and SVG-path shape
  • render or call counts on mocks
  • harness self-checks
  • documentation inventories

No production code changes. Net −4,199 lines across 51 files.

How cuts were chosen

Candidates came from a read-only audit. Before each delete:

  • A "covered by X" claim was checked against X.
  • If the claim did not hold, or the test guarded real behavior, it was kept. That covers caret, persistence, revocation, origin, screen-reader semantics, Save-Data and worker cleanup.

About a third of the candidates were kept this way, for example:

  • agents/tabs
  • AgentAvatar
  • prepared.test.ts:315 (revocation)
  • view-key
  • composer format/IME guards
  • DeliveryNotice
  • MessageTimestamp
  • encode-webp

Agent review then found five deleted cases that were the only falsifier for real behavior. The second commit restores them in compact form:

Restored Owner Fail-then-pass
A lifetime save retired by visit or unmount while signing is held never publishes; a parent-linked session stays ineligible sessions/SessionLifetime.test.tsx, trimmed to these cases with the real details owner Dropping the save's abort signal fails both retirement rows
Oversized originals are never explicitly decoded relay/media.test.ts, a two-row table Raising the 8 MiB budget to Infinity fails the oversized row
Adding a custom emoji rebuilds the own set from a fresh read and fails closed on read failure relay/emoji.test.ts, restored unchanged Existing tests
Account avatar and Availability keep 4.5:1 contrast through hover and press in both themes tests/browser/profile-contrast.spec.mjs, the contrast half of profile-avatar-gap Passes on Chromium and WebKit
Thinking badge reverses mid-morph and settles immediately under reduced motion viewer.spec.ts Not run; see below

Browser cases removed

Each row gives the browser-only justification it had and what now covers it:

Removed What covers it now
channel-activity-corners: popup inset radii Opening an unread thread from Activity: thread-unread.spec "thread buttons show observed unread…"
scrollbar-polish: scrollbar colour, width and gutter Settings wheel-scroll reachability: layout.spec:925–970
app-style-order: hover colour after token injection Search open, Escape and focus return: global-search.spec "search arrows traverse…"
profile-avatar-gap: cutout paint and theme highlights Menu keys and dismissal: settings.spec "avatar Settings access…" and account-profile.spec. Contrast is kept in profile-contrast.spec
Paint asserts in quote-styling, message-content-polish, message-delivery-polish, profiles-appearance The same specs keep focus, keyboard, Retry, overflow, forced-colours and contrast behavior
Visual matrices in viewer.spec.ts: typography ramp, status cutout, button size, offsets, motion paint The viewer keeps its keyboard, focus, form-reset, overflow and reduced-motion journeys

Coverage given up on purpose

  • In a short viewport, the last row of the activity popover is reachable by scrolling.
  • Unit coverage of useMediaCorners path generation, which is visual only.
  • Native Arrow-key traversal through status Duration → Custom → expiry. StatusEditor.test.tsx still covers selection and validation.
  • Jump-to-latest focus surviving an activity-lane flip.

Validation (head cb32e0b65)

Rebased onto main after #1218 and #1262. #1218 reworked three of the MessageRow tests this PR deleted: own-row alignment, attachment placement, and thread-root styling. This PR keeps #1218's new versions and leaves them for the phase 3 merges. It also keeps the new delivery-polish settle before scrolling.

  • Typecheck: bin/pnpm typecheck and bin/pnpm design:typecheck are clean.
  • Lint: biome is clean on the changed files.
  • Unit tests: the pre-push full Vitest run passed 9,802. The only failure was a 5s timeout in the untouched InboxPage.test.tsx, which passed in isolation.
  • Browser:
    • The trimmed browser specs passed on Chromium (19 tests).
    • profile-contrast.spec and the merged message-delivery-polish.spec passed on Chromium and WebKit (6 tests).
  • Restored cases: mutation-checked as shown in the table above.
  • Not run: tests/fixtures/design-system/viewer.spec.ts. On main it fails to load before any test runs, at src/shared/design-system/icons/claude.png: Unexpected character. It only runs from just scan, not from CI. That is pre-existing and left for a separate fix.

🤖 Generated with Claude Code

wesbillman and others added 2 commits October 16, 2026 09:44
Phase 1 of the test-suite slimming. Removes tests that only freeze paint
(radius, RGB, margins, fonts), markup/class/data-attribute shape, render or
call counts on mocks, harness self-checks and documentation inventories.
Behavior they carried is either already covered by a named journey or kept
in a trimmed form. Items whose "covered elsewhere" claim did not hold on
inspection were kept.

No production code changes.

Co-authored-by: Carl <32a2e2c9d428ee08902cab75d956da2c1d235a22d4766b0dd4138bf6e2e5db1d@buzz.block.builderlab.xyz>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Signed-off-by: Wes <wesbillman@users.noreply.github.com>
Court review of the trivia cuts found five cases that were the only
falsifier for real behavior. Restore them in compact form:

- a lifetime save retired by its visit or unmount while signing is held
  never publishes, and parent-linked sessions stay ineligible
- oversized originals are never explicitly decoded for avatar warming
- adding a custom emoji rebuilds the own set from a fresh relay read and
  fails closed when that read fails
- the account avatar and Availability control keep 4.5:1 contrast through
  hover and press in both themes
- the thinking badge reverses mid-morph and settles at once under reduced
  motion

Co-authored-by: Carl <32a2e2c9d428ee08902cab75d956da2c1d235a22d4766b0dd4138bf6e2e5db1d@buzz.block.builderlab.xyz>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Signed-off-by: Wes <wesbillman@users.noreply.github.com>
@wesbillman
wesbillman force-pushed the carl/test-trivia-cuts branch from 9affc70 to cb32e0b Compare October 16, 2026 16:51
@wesbillman
wesbillman marked this pull request as ready for review October 16, 2026 17:18
@wesbillman
wesbillman requested a review from a team as a code owner October 16, 2026 17:18
@wesbillman
wesbillman merged commit 19b25e8 into main Oct 16, 2026
35 checks passed
@wesbillman
wesbillman deleted the carl/test-trivia-cuts branch October 16, 2026 17:36
tellaho added a commit that referenced this pull request Oct 16, 2026
…ui-polish

* buzz-app/main:
  test: delete styling, markup and call-count trivia tests (#1255)
  fix(hooks): preserve recovery ownership on lefthook 2.2.2 (#1174)
  fix(deps): upgrade vulnerable tls and editor dependencies (#1267)
  chore(terminal): upgrade xterm with compatible navigation (#1268)
  feat(goose): show goose and provider marks on agent cards (#1260)

Signed-off-by: Taylor Ho <taylorkmho@gmail.com>
johnmatthewtennant added a commit that referenced this pull request Oct 16, 2026
…lation

* origin/main: (139 commits)
  feat(agents): let plugins read each agent's sessions (#1111)
  chore(deps): upgrade vitest to 5.0.4 (#1272)
  feat(plugins): reload folder plugins from the CLI (#1265)
  add channel shared sessions discovery and retrieval (#1254)
  polish Solo activity layout and fold previous steps (#1257)
  fix(agents): clarify model defaults and provider actions (#1177)
  fix(messages): stop the channel timeline jumping back when agents or search read old messages (#1256)
  Add Close other tabs to the tab menu (#1127)
  chore(deps): upgrade virtua to 0.53.5 and port its scroll patch (#1269)
  Auto-tag Berd drafts with a chosen default agent (#1139)
  test: delete styling, markup and call-count trivia tests (#1255)
  fix(hooks): preserve recovery ownership on lefthook 2.2.2 (#1174)
  fix(deps): upgrade vulnerable tls and editor dependencies (#1267)
  chore(terminal): upgrade xterm with compatible navigation (#1268)
  feat(goose): show goose and provider marks on agent cards (#1260)
  fix(agents): show native agent pictures in the Solo agent picker (#1258)
  test(agents): fix main typecheck — add effort to Goose fixture (#1262)
  fix(messages): reject unclaimed file and link drops app-wide (#1075)
  feat(channels): create and read system channels (#965)
  Refine message layout and bubble reading widths (#1218)
  ...
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