You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
test: remove 158 low-value test declarations - #38177
Remove tests whose maintenance and CI cost outweigh their regression value.
Files
Added
Deleted
Net
Test
47
$\color{#1a7f37}{\Huge{\mathbf{+}}}$18
$\color{#cf222e}{\Huge{\mathbf{−}}}$3566
$\color{#cf222e}{\Huge{\mathbf{−}}}$3548
Prod
3
$\color{#1a7f37}{\Huge{\mathbf{+}}}$17
$\color{#cf222e}{\Huge{\mathbf{−}}}$38
$\color{#cf222e}{\Huge{\mathbf{−}}}$21
What Changed
Remove 158 authored declarations from 60 reviewed renderer sources: ten whole suites, 37 partial suites, and 13 unchanged suites. Deleted cases chiefly repeat private predicates, static copy and catalogs, supplied mock values, implementation counters, and helper characterization.
Preserve 101 authored declarations protecting ownership, lifecycle races, reconnect behavior, resource cleanup, actual store selection, editor reconciliation, and mixed-version remote behavior. Retain the structured-session navigation table across all four consumers after a second value review.
Remove nine obsolete timing rows, retire one affected complete historical receipt into a verbatim archive, reconcile two reliability gates, and lower one wall-clock baseline count from two to one after deleting its test. No production behavior changes.
Why
Each source was reviewed with its decisive production owner. The audit records intentional coverage losses without claiming equivalent replacements. Whole-suite deletion is appropriate when all its cases have little regression value.
Linked Issue
Maintainer-directed test audit; no separate issue required under the repository's maintainer exception.
Visual Proof
N/A — tests and test metadata only; no production UI or interaction change.
Testing
All 31 final check:changed checks passed on Linux against the actual merged base.
All 50 retained test roots passed: 129 expanded cases, no skips.
Static review preserved surviving callbacks and wrapper context, found no surviving importers of deleted suites, and retained 19 affected support paths with 1,085 consumers.
Actual merged-base and candidate trees authenticated against the privately validated trees.
Tests/apps used background launch on an isolated display. Validation used byte-identical local dependency copies and isolated caches to avoid pnpm shared-store WASM URL restrictions. No manual macOS/Windows/SSH validation is claimed. The renderer sources and production code remain identical to the runtime-tested tree. Later changes lower the baseline count and inherit the separately validated queue-scale correction from the base; final checks passed afterward.
AI Disclosure
Internal maintainer-directed change.
Review
Self-reviewed and independently value-reviewed. Historical receipts and intentional losses remain explicitly archived; local runs do not promote reliability-gate claims.
Agent skill upstream boundary
Not applicable; no upstream skill-installer material copied or translated.
Notes
Removal credit counts authored registrations once; expanded table rows receive no extra credit. Full PR CI must pass before merge.
Checklist
Focused on reviewed low-value tests and their inventories.
Change and rationale explained.
Visual proof marked N/A with reason.
Self-reviewed for correctness, security, and performance.
Cross-platform, remote, mobile, and mixed-version impact considered.
Local checks passed; full PR CI required before merge.
The pull request removes or narrows tests across renderer application surfaces, editor and browser features, chat and AI vault features, runtime interactions, and state coordination. It adds a test for host-aware workspace reference refresh targets. It also decreases one flaky-test baseline count and removes CI timing entries for deleted test files.
Pre-merge checks: 5
Check name
Status
Explanation
Title check
The title "test: remove 158 low-value test declarations" matches the main change. The PR removes 158 authored test declarations across 60 renderer sources, and the summary confirms the test-only remov…
Description check
The description follows the repository template and fills in most required sections. It gives an ELI5, a detailed What Changed, a Why, testing evidence, a risk-free statement for a test-only change, a…
Docstring Coverage
No eligible functions found in the changed files. Skipping docstring coverage check. Docstring coverage is scoped to functions touched by this diff with cyclomatic complexity of at least 2. Documentat…
Linked Issues check
Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check
Check skipped because no linked issues were found for this pull request.
Full details: Title check
Explanation
The title "test: remove 158 low-value test declarations" matches the main change. The PR removes 158 authored test declarations across 60 renderer sources, and the summary confirms the test-only removals. It does not name the 101 retained declarations or the minor metadata edits (timing rows, baseline count), which is expected for a title.
Full details: Description check
Explanation
The description follows the repository template and fills in most required sections. It gives an ELI5, a detailed What Changed, a Why, testing evidence, a risk-free statement for a test-only change, and checklist items. Gaps: the Linked Issue section has no issue reference ("Fixes #" is blank), and the author states a maintainer exception applies. The Risk section has no Level value and no back-out guidance. The Visual Proof N/A reason is given. The AI Disclosure section is filled in. The Why section gives a short rationale but does not compare the approach to alternatives.
Resolution
Consider these additions for completeness: set the Risk Level (for example, Low, since only tests change), state how to back out (a plain revert restores the tests), and confirm the maintainer exception for the linked issue.
Full details: Docstring Coverage
Explanation
No eligible functions found in the changed files. Skipping docstring coverage check. Docstring coverage is scoped to functions touched by this diff with cyclomatic complexity of at least 2. Documentation-only edits and deletions within surviving functions are included; unchanged diff context and fully deleted functions are excluded. Analyzed 0 functions across 13 files. (1 skipped: 1 unsupported.)
Finishing Touches
Generate docstrings
Commit to this branch
Create a new PR
Autofix · Keep fixing CodeRabbit findings and required CI, and resolving merge conflicts
Warning
Review coverage is incomplete: 1 file could not be fully reviewed. Findings from completed review steps are included; see review info for details.
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.
When activeWorkspaceExecutionHostId is 'ssh:remote', the selected remote owner bypasses the local visibility filter. Assert that the sole selected target has the key for the 'ssh:remote' owner. This makes the test reject selection of the wrong owner.
49-54: Trivial · Data Integrity & Integration · Quick win
Restore the all-profile startup parity check for persisted sessions.
The remaining tests in this file cover only two profiles. A Loader or Serializer change that drops a stored tab or changes the active terminal in another profile does not fail here. Restore the parameterized comparison. It checks that each stored workspace stays visible and that view differences match the recorded known and accepted ledger.
The patch replaces the existing fixture import. Do not keep the old GIT, sweptAtStartup line beside a new import from the same module, because duplicate bindings fail to parse.
Suggested fix
-import { GIT, sweptAtStartup } from './startup-window-parity-differences.test-fixture'+import {+ ACCEPTED_DIFFERENCES,+ GIT,+ KNOWN_DIFFERENCES,+ sweptAtStartup+} from './startup-window-parity-differences.test-fixture'
import {
bootWindowFromPartitions,
+ diffStartupWindowViews,
projectStartupWindowView
} from './startup-window-view.test-fixture'
const PROFILES = [...WORKSPACE_LAYOUT_PROFILES, ...LEGACY_WORKSPACE_LAYOUT_PROFILES]
describe('the window shows the same session before and after the shared Loader rewrites it', () => {
+ it.each(PROFILES.map((profile) => [profile.name, profile] as const))(+ '%s',+ async (name, { hostId, build }) => {+ const stored = build()+ const storedView = projectStartupWindowView(+ await bootWindowFromPartitions(createTestStore(), [{ hostId, session: stored }])+ )+ const normalizedView = projectStartupWindowView(+ await bootWindowFromPartitions(createTestStore(), [+ { hostId, session: normalize(hostId, stored) }+ ])+ )+ for (const [key, rows] of Object.entries(stored.tabsByWorktree)) {+ if (rows.length > 0) {+ expect(storedView, key).toHaveProperty([`${key} group 0 tabs`])+ }+ }+ const differences = diffStartupWindowViews(storedView, normalizedView)+ const known = KNOWN_DIFFERENCES.filter((entry) => entry.fixture === name)+ const accepted = ACCEPTED_DIFFERENCES.filter((entry) => entry.fixture === name)+ expect(+ differences.map((difference) => difference.path).sort(),+ `window differences (stored vs normalized):\n${JSON.stringify(differences, null, 2)}`+ ).toEqual(+ [+ ...known.flatMap((entry) => entry.paths),+ ...accepted.flatMap((entry) => Object.keys(entry.values))+ ].sort()+ )+ const acceptedValues = Object.assign({}, ...accepted.map((entry) => entry.values))+ expect(+ Object.fromEntries(+ differences+ .filter((difference) => difference.path in acceptedValues)+ .map(({ path, stored, normalized }) => [path, { stored, normalized }])+ )+ ).toEqual(acceptedValues)+ }+ )+
it('keeps the tab-bar twin selected when a selected legacy copy is dropped', async () => {
Review info
Run configuration
Source mode: Auto
Repository: Unavailable
Branch: Unavailable
File: No configuration file from this repository applied
Commit: Unavailable
Layers: Repository UI
Review profile: CHILL
Plan: Advanced
Run ID: b9aa4c1c-d61e-42a9-b29e-c3a76114350d
Commits
Reviewing files that changed from the base of the PR and between 2270f75 and 1d1ec8a.
Files not fully reviewed because their changes were unavailable: 1
config/reliability-gates.jsonc
Included review availability: This review used your included allowance. Your plan provides up to 10 included reviews per hour; 7 remain after this review.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
ELI5
Remove tests whose maintenance and CI cost outweigh their regression value.
What Changed
Remove 158 authored declarations from 60 reviewed renderer sources: ten whole suites, 37 partial suites, and 13 unchanged suites. Deleted cases chiefly repeat private predicates, static copy and catalogs, supplied mock values, implementation counters, and helper characterization.
Preserve 101 authored declarations protecting ownership, lifecycle races, reconnect behavior, resource cleanup, actual store selection, editor reconciliation, and mixed-version remote behavior. Retain the structured-session navigation table across all four consumers after a second value review.
Remove nine obsolete timing rows, retire one affected complete historical receipt into a verbatim archive, reconcile two reliability gates, and lower one wall-clock baseline count from two to one after deleting its test. No production behavior changes.
Why
Each source was reviewed with its decisive production owner. The audit records intentional coverage losses without claiming equivalent replacements. Whole-suite deletion is appropriate when all its cases have little regression value.
Linked Issue
Maintainer-directed test audit; no separate issue required under the repository's maintainer exception.
Visual Proof
N/A — tests and test metadata only; no production UI or interaction change.
Testing
check:changedchecks passed on Linux against the actual merged base.Tests/apps used background launch on an isolated display. Validation used byte-identical local dependency copies and isolated caches to avoid pnpm shared-store WASM URL restrictions. No manual macOS/Windows/SSH validation is claimed. The renderer sources and production code remain identical to the runtime-tested tree. Later changes lower the baseline count and inherit the separately validated queue-scale correction from the base; final checks passed afterward.
AI Disclosure
Internal maintainer-directed change.
Review
Self-reviewed and independently value-reviewed. Historical receipts and intentional losses remain explicitly archived; local runs do not promote reliability-gate claims.
Agent skill upstream boundary
Notes
Removal credit counts authored registrations once; expanded table rows receive no extra credit. Full PR CI must pass before merge.
Checklist