Repository navigation
refactor: remove test-only seams, dead option fields, and duplicate tests - #3308
Conversation
…ests - DaemonError is NormalizedError; one wire shape instead of two copies - host-kit: one override-path resolver, inline the canceled-command wrapper, and export the abort-aware sleep instead of a second module - provision-kit: drop the downloadTimeoutMs option no caller supplies - android observation reads blocking dialogs through app-parsers - delete shutdownSimulator, providerDeviceAdmission(), the unused CoordinateGesturePayload, getCloseShutdown, prefixItems, and selectMaestroSnapshotMatches, each reachable only from tests - import isLikelyStaleSnapshotDrop instead of a verbatim copy - drop five tests that restated a sibling or their own input, and wire the never-run integration-progress model test into check:affected:test Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
…CHECKS Each removed test had a stronger owner in the same or a neighbouring file: a byte-identical plan-validator case, idle-reap and surface-signature cases implied by a tolerance test, a perf positional case subsumed by the case-insensitive one, interactor-catalog subsets of the seven-operation test, hint regexes duplicated by exact pins, a stub-client clipboard case covered through the real CLI, and a zip fixture nothing imports. The check-id union and the ALL_CHECKS array listed the same 59 ids twice; the type is now derived from the array. Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
DaemonError is now declared as an alias of NormalizedError; the members were already field-for-field identical, so no wire byte changes and the ack records the moved declaration text. Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
|
Size Report
Startup median (7 runs, lower is better):
|
|
This PR is ready at 12b9b97. The removed seams, dead option fields and duplicate tests look right to me, and I found nothing that needs a change. Not blocking: wiring scripts/integration-progress-model.test.ts into check:affected:test in package.json (https://github.com/callstack/agent-device/blob/12b9b97/package.json#L151) is a second change in a deletion PR, and that test may not be selected when only scripts/integration-progress-model.ts changes, so you can register it under the gate that owns integration-progress or explain why affected-selector owns it, or leave it as is. The affected decision-kernel check failed only because two of eight mutant shards (kernel-errors and selectors-2) were cancelled, so it reported "Incomplete shard set: 6 report(s), expected 8". No test failed. I could not see why they were cancelled. selectors-2 does not touch this diff. For kernel-errors, the changes are a type-only alias and three removed tests whose hint assertions are still pinned per code, so I expect the same result. I did not run any tests myself. There are no conflicts. Please rerun the two cancelled shards so the check gets all eight reports before merge. |
Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
|
The two cancelled shards are the 30-minute job budget, not a test failure, and they reproduce outside this branch:
This PR's diff touches |
Touching scripts/mutation/ classifies a PR as a harness change and runs the full mutant sweep, which the single-file kernel-errors shard no longer finishes inside its 30-minute budget. The one-line cleanup is not worth that lane. Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
|
This PR is ready at fea10e9. The earlier clean review at 12b9b97 still holds, and nothing new needs a change. Not blocking: deleting selectMaestroSnapshotMatches also removed the only test that resolved a childOf parent selector with its own index, and The failing check looks unrelated to the change. The PR does touch No conflicts. Before merge, a completed kernel-errors mutation shard is needed, either by rerunning it or by raising the job budget. Until then the decision-kernel aggregator keeps failing at the score stage for any PR that touches |
|
Mutation lane fixed at 70aa643: the only reason the sweep ran here was the one-line cleanup in |
|
This PR is ready. The earlier review at fea10e9 found no problems, and 70aa643 only changes one test assertion, so that result still holds. All checks pass, and there is no production code overlap in the new commit. It merges cleanly with current main. I did not re-check the older commits beyond the range-diff, which shows them identical. Not blocking: deleting the |
Summary
Production code reachable only from tests, option fields no caller sets, and tests that restated a sibling:
DaemonErroris now an alias ofNormalizedError(field-for-field identical; wire ledger ack in the final gates commit).sleepexported fromretryinstead of a second module.downloadTimeoutMsoption no caller supplies; Android observation reads blocking dialogs throughapp-parsersinstead of a verbatim copy.shutdownSimulator,providerDeviceAdmission(),CoordinateGesturePayload,getCloseShutdown,prefixItems, andselectMaestroSnapshotMatches: each had zero production references.isLikelyStaleSnapshotDropis imported from capture-kit instead of duplicated;CheckIdderives fromALL_CHECKSinstead of a second 59-member list.integration-progress-model.test.tsis now wired intocheck:affected:test.39 files, net −473 lines.
Validation
Tested at 12b9b97:
pnpm check:affected --runpassed (format, lint, typecheck, daemon-wire-compat, related unit tests, check-affected and mutation node tests, output-economy project). No device run applies.🤖 Generated with Claude Code