Repository navigation
test(core,plugins): remove low-value tests (batch d057) - #169570
Conversation
|
🦞👀 Pull request received. I will update this pull request when review starts. ClawSweeper review completeClawSweeper finished reviewing this revision. The review result is being finalized. |
|
Codex review: needs changes before merge. What this changesThis PR removes redundant tests and test fixtures across core and plugins, plus an obsolete line-count baseline entry. Example: A bounded HTTP response yields "partial" and then its reader throws.
Review scores
ProductKind: Test only · Worth it: Yes · Fix scope: Complete Merge readiness⛔ Needs changes before merge - 4 items remain This PR offers useful test cleanup, but both previously reported P2 coverage losses remain in the reviewed head and need correction before merge. Priority: P3 Before merge
Findings
Provenance
Agent review detailsHow this fits togetherThese tests protect core and plugin contracts by passing fixtures through web-response readers, channel helpers, configuration owners, and worker lifecycle stores. flowchart TD
A[Test fixtures] --> B[Core owners]
A --> C[Plugin adapters]
C --> B
B --> D[Response and lifecycle results]
D --> E[Contract assertions]
Technical reviewBest possible solution: Keep the redundant-test reductions while restoring the interrupted-read contract and five prepared-assignment identity cases. Do we have a high-confidence way to reproduce the issue? The pinned diff and surviving tests establish both coverage losses directly; no target code or tests were executed during this read-only review. Is this the best way to solve the issue? Removing redundant tests is worthwhile, but statement and branch coverage totals do not demonstrate that the two deleted contracts have equivalent remaining assertions. Full review comments:
Overall correctness: patch is incorrect AGENTS.md: found and applied where relevant. Codex review notes: model internal, reasoning medium; reviewed against 6fcd0488021d. TestingProof path: in-process harness. SecurityNone. EvidenceAcceptance criteria:
What I checked:
PR surfacePR surface statistics unavailable: the file list is incomplete. Review metrics
LabelsLabel changes: No label changes. Label justifications:
Rating scale6/6 🦀 challenger crab · 5/6 🦞 diamond lobster · 4/6 🐚 platinum hermit · 3/6 🦐 gold shrimp · 2/6 🦪 silver shellfish · 1/6 🧂 unranked krab. Overall follows the weaker of proof and patch quality; ✨ marks media proof (a screenshot, video, or linked artifact) that directly shows the changed behavior. WorkflowClawSweeper edits this one comment on every review. Comment HistoryReview history (2 earlier review cycles)
Reviewed October 12, 2026, 12:38 AM ET / 04:38 UTC (Revision 3). |
|
Fixed the two CI lint failures in
Blacksmith Testbox Updated totals: test code +754 / -11,206 lines (net -10,452); production +0 / -0; baseline +0 / -1. The x1235 declaration reduction is 35 rather than 36 after retaining that case. The original shard coverage measurements and documented inherited dead-export proof remain unchanged. All other jobs, including every executed test job, passed on the first head; new-head CI remains authoritative. |
ca2af60 to
58fff3d
Compare
|
The corrected head encountered an inherited merge-base type error in Main fixed it in |
) * test(infra): deslop x1232 tests * test(codex): deslop x1186 tests * test(secrets): deslop x1227 tests * test(config): deslop x1223 tests * test(channels): deslop x1237 tests * test(gateway): deslop x1235 tests * test(agents): deslop x1242 tests * test(infra): deslop x1241 tests * test(test): deslop x1240 tests * test(agents): deslop x1245 tests * test: retain distinct security and restart contracts * test: preserve classification coverage and remove stale suppression
First-parent upstream 2b9aa2e..fa23864 (100 commits). Conflicts: - agent-runner-helpers.ts / agent-runner-run.ts: upstream moved the verbose-gate session read into session-verbose-level.ts (prepareSessionVerboseLevelReader); import unions with our progress-visibility settlement and run-provenance trigger. - session-delivery-queue.storage.test.ts: upstream openclaw#169570 removed two low-value cases (idempotency-key dedupe, retry metadata + tombstone); removed them from our copy too, fork cases kept. - config-baseline sha256 and worker inventory regenerated. Auto-merged files carrying continuation overlay (16) keep it byte-for-byte. Refs #1475 Co-Authored-By: Claude Opus 5.5 <[email protected]>
) Doctor's Codex repair removed the still-used host summary/compaction model together with unsupported provider overrides. It now preserves and normalizes that model while still cleaning provider overrides and keeping Lossless migration behavior. Supersedes #175799, thanks @scotthuang. Release adaptation: production applied cleanly. The new repair case uses maybeRepairCodexRoutes directly because the stable test lacks the main-only repairFixture helper. The stable-only case for shared defaults with a non-Codex override (removed on main by #169570) now expects the shared compaction.model to be kept and the provider-only manual hint. Co-authored-by: scotthuang <[email protected]> (cherry picked from commit 399a360)
What Problem This Solves
Redundant test variants and implementation-mirroring assertions add maintenance and execution cost without independent behavioral proof. This is the single d057 campaign batch.
User Impact
No user-visible behavior change, production implementation change, migration, or configuration change. Distinct security, live-authority, lifecycle, and regression cases remain.
Why This Change Was Made
Replays ten coverage-gated test reductions onto current main. Deletes redundant cases and unused test-local fixture pieces; does not replace assertions with weaker ones or fold cases to inflate counts. One obsolete max-lines baseline entry is removed (shrink-only).
Replay base:
992410c17ab7812ff7726b25cb93fd7dca6a8e75. All ten commits applied; none skipped. Two conflicts: in the SQLite native-resource test, main had already removed the failed-allocation table, so that hunk was dropped and only the remaining duplicate error-graph case was deleted. In the Codex index test, main's async auth-store import and current fixtures were preserved while applying the intended test deletions. All other hunks merged directly.Review follow-up
fffab87d2b389e28bc3e746f77e34b80716b461dretains five independently useful contracts: fail-closed MCP annotations, singular voice status redaction through the current async record reader, hidden CSS/class sanitization, provisioning across service/store restart, and every durable portal authority field. All five findings were accepted; none rejected. The full batch review and a clean corrective-patch review cover the final tree.Evidence
oxfmt,git diff --check, and plainoxlint: passed.CI=1 pnpm test <all surviving changed test paths>: passed on Blacksmith Testboxtbx_01m4pvs2cn913vrd9ee749dke5, 538.6 s command time including preparation. Two unchanged Gateway tests were also included as sibling coverage. Testbox run.CI=1 pnpm test src/agents/mcp-codex-tool-approval.test.ts extensions/voice-call/index.test.ts src/agents/tools/web-fetch-visibility.test.ts src/gateway/worker-environments/portal-node-carrier.test.ts src/gateway/worker-environments/provider-provisioning.replay.test.ts: all 134 tests passed; 120.8 s command time including preparation, same Testbox.OPENCLAW_TESTBOX=1 node scripts/check-changed.mjs --base 992410c17ab7812ff7726b25cb93fd7dca6a8e75 -- <changed paths>: all preceding guards, formatting, core-test types, extension-test types, and root-test types passed; only the repository-wide dead-export scan failed. Command time 1,815.2 s. Changed-check run.6ce48cb2d3250187ae0006c793e100f775a36cfb, ran frozen dependency installation followed by the exact failing commandnode --import tsx scripts/check-deadcode-exports.mts. Both scans exited 1. Candidate and replay-base diagnostics are identical: 88 unique path/symbol diagnostic entries (including alias contexts), zero candidate-only or base-only entries. All 88 also occur on current main (111 entries). None of the failing source paths is touched by this batch. Baseline run, Testboxtbx_01m4q0pxaz9tk0e797zkexgjj3.b6f1ce020882b197cdc83d183b4ae23560784052.All completed leases were stopped. One baseline setup attempt stalled in cold source-copy preparation and was cancelled; its lease
tbx_01m4q0ga7q13sqnx63rqe9ct0cwas confirmed stopped, and no scan result from that attempt is counted. Hosted CI remains the merge gate; the local inherited failure is disclosed, not called green.Original in-shard coverage totals are below, not a claim of remeasuring coverage on this replay. All comparable groups stayed within the 1% statement/branch budget. x1186 excluded its unchanged failing media group (three stale retry cases); x1245 excluded a baseline-failed seven-file group. Original reports also document inherited dead-export failures; those historical failures are not used as a waiver for this PR's checks.
The final diff contains 123 test files: +755 / -11,206 lines, net -10,451. Production code: +0 / -0. Other tooling/config: +0 / -1 (max-lines baseline). No CODEOWNERS-listed path is touched. Per-shard deltas below include the review restorations and count declarations only in the changed files.
Per-shard files, replay deltas, and original coverage
x1232
Applied commit:
cd26eb075687ecacddf86dc1284c60bf6a981cb8. Test LOC +99 / -586 (net -487); declarations 114 → 96 (-18). Original coverage: statements 8,340 → 8,318; branches 4,909 → 4,892.src/infra/session-delivery-queue.storage.test.tssrc/infra/session-event-wake-concurrency.test.tssrc/infra/sqlite-audit-record-store.test.tssrc/infra/sqlite-index-schema.test.tssrc/infra/sqlite-integrity.test.tssrc/infra/sqlite-number.test.tssrc/infra/sqlite-readonly-native-resource.test.tssrc/infra/sqlite-readonly-worker-session.test.tssrc/infra/sqlite-schema-contract.test.tsx1186
Applied commit:
97715683fb2bba6bac497d8eb5826f7af801ec4a. Test LOC +54 / -954 (net -900); declarations 191 → 141 (-50). Original coverage: statements 3,756 → 3,755; branches 1,931 → 1,929.extensions/codex/index.test.tsextensions/codex/session-history-worker-runtime.test.tsextensions/qa-lab/src/live-transports/whatsapp/whatsapp-live.runtime.test.tsextensions/voice-call/index.test.tssrc/commands/migrate/output.test.tssrc/commands/migrate/selection.test.tssrc/commands/migrate/skill-selection-prompt.test.tssrc/transcripts/store.test.tssrc/transcripts/summary-model.test.tsx1227
Applied commit:
5fe51fd7f62c66de5d0a0e6f68dc694d1fb46ea0. Test LOC +12 / -1369 (net -1357); declarations 179 → 135 (-44). Original coverage: statements 2,748 → 2,747; branches 2,159 → 2,154.src/secrets/apply.test.tssrc/secrets/audit.test.tssrc/secrets/channel-contract-api.external.test.tssrc/secrets/configure-plan.test.tssrc/secrets/path-utils.test.tssrc/secrets/provider-integrations.test.tssrc/secrets/ref-contract.test.tssrc/secrets/resolve-store.test.tssrc/secrets/runtime-auth-store-inline-refs.test.tssrc/secrets/runtime-config-collectors-plugins.test.tssrc/secrets/runtime-core-snapshots.test.tssrc/secrets/runtime-degradation-attribution.test.tssrc/secrets/runtime-gateway-auth-surfaces.test.tssrc/secrets/runtime-gateway-local-surfaces.test.tssrc/secrets/runtime-provider-and-media-surfaces.test.tsx1223
Applied commit:
a67b07c41f4e774f0735bb3a7d9a881369177f4b. Test LOC +3 / -2239 (net -2236); declarations 182 → 105 (-77). Original coverage: statements 3,294 → 3,294; branches 2,450 → 2,449.config/max-lines-baseline.txtsrc/commands/doctor/shared/allowfrom-fallback-migration.test.tssrc/commands/doctor/shared/bundled-plugin-load-paths.test.tssrc/commands/doctor/shared/channel-plugin-blockers.test.tssrc/commands/doctor/shared/codex-route-session-repair.test.tssrc/commands/doctor/shared/codex-route-warnings.test.tssrc/commands/doctor/shared/config-flow-steps.test.tssrc/commands/doctor/shared/context-engine-host-compat.test.tssrc/commands/doctor/shared/default-agent-role-materialization.test.tssrc/commands/doctor/shared/default-agent-role-materialization.write.test.tssrc/commands/doctor/shared/empty-allowlist-scan.test.tssrc/commands/doctor/shared/exec-safe-bins.test.tssrc/commands/doctor/shared/hooks-token-reuse-repair.test.tssrc/commands/doctor/shared/include-migration-ownership.test.tssrc/commands/doctor/shared/invalid-plugin-config.test.tssrc/commands/doctor/shared/legacy-config-migrations.runtime.models.test.tsx1237
Applied commit:
8586936dae1092724e0084620de23f7f7a95fc8d. Test LOC +90 / -1373 (net -1283); declarations 180 → 120 (-60). Original coverage: statements 1,615 → 1,615; branches 1,519 → 1,516.src/channels/account-snapshot-fields.test.tssrc/channels/allow-from.test.tssrc/channels/bundled-channel-catalog-read.test.tssrc/channels/channel-config.test.tssrc/channels/command-gating.test.tssrc/channels/config-presence.test.tssrc/channels/conversation-resolution.test.tssrc/channels/draft-stream-controls.test.tssrc/channels/draft-stream-loop.test.tssrc/channels/location.test.tssrc/channels/mention-gating.test.tssrc/channels/model-overrides.test.tssrc/channels/progress-draft-compositor.test.tssrc/channels/sender-label.test.tssrc/channels/session.test.tsx1235
Applied commit:
2b056c898dbe5e139c01b0625a9d3e34c55131af. Test LOC +182 / -1471 (net -1289); declarations 178 → 142 (-36). Original coverage: statements 7,024 → 7,022; branches 4,396 → 4,389.src/gateway/worker-environments/placement-session-runtime.test.tssrc/gateway/worker-environments/placement-store-terminal.test.tssrc/gateway/worker-environments/portal-node-carrier.test.tssrc/gateway/worker-environments/prepared-environment-store.test.tssrc/gateway/worker-environments/prepared-pool-presence.test.tssrc/gateway/worker-environments/prepared-pool.test.tssrc/gateway/worker-environments/project-preparation.test.tssrc/gateway/worker-environments/provider-allocation-cleanup.test.tssrc/gateway/worker-environments/provider-bootstrap.test.tssrc/gateway/worker-environments/provider-intent.test.tssrc/gateway/worker-environments/provider-project-preparation.test.tssrc/gateway/worker-environments/provider-project-retention.test.tssrc/gateway/worker-environments/provider-provisioning-node.test.tssrc/gateway/worker-environments/provider-provisioning.cancellation.test.tssrc/gateway/worker-environments/provider-provisioning.replay.test.tssrc/gateway/worker-environments/provider-provisioning.test.tsx1242
Applied commit:
0a8771befe0ce1e639ce706c7a53100dcc449fc0. Test LOC +82 / -958 (net -876); declarations 184 → 116 (-68). Original coverage: statements 916 → 916; branches 798 → 797.src/agents/tools/web-fetch-utils.test.tssrc/agents/tools/web-fetch-visibility.test.tssrc/agents/tools/web-guarded-fetch.test.tssrc/agents/tools/web-search-output.security.test.tssrc/agents/tools/web-search-provider-credentials.test.tssrc/agents/tools/web-shared.test.tssrc/agents/tools/web-tools.fetch.test.tsx1241
Applied commit:
502333fbc643390fae850066bc84909dbe7e9e09. Test LOC +51 / -357 (net -306); declarations 124 → 111 (-13). Original coverage: statements 8,355 → 8,347; branches 5,287 → 5,284.src/infra/update-failure-report.test.tssrc/infra/update-freebsd-pkg-ownership.test.tssrc/infra/update-global-lifecycle.test.tssrc/infra/update-immutable-install.test.tssrc/infra/update-immutable-service.test.tssrc/infra/update-immutable-verification.test.tssrc/infra/update-managed-service-handoff-command.test.tssrc/infra/update-managed-service-handoff-cross-process.test.tssrc/infra/update-managed-service-handoff-native.test.tssrc/infra/update-managed-service-handoff-ownership.test.tsx1240
Applied commit:
8672b247aeabe064824cf3c68056c331209cc21c. Test LOC +148 / -902 (net -754); declarations 157 → 115 (-42). Original coverage: statements 2,055 → 2,055; branches 1,238 → 1,238.test/scripts/docker-stats-resource-ceiling.test.tstest/scripts/docs-component-attributes.test.tstest/scripts/docs-list.test.tstest/scripts/docs-markdown.test.tstest/scripts/docs-sync-publish.test.tstest/scripts/doctor-install-switch-wrapper.test.tstest/scripts/e2e-agent-turn-output.test.tstest/scripts/e2e-helper-env-limits.test.tstest/scripts/e2e-mock-config-limits.test.tstest/scripts/ensure-cli-startup-build.test.tstest/scripts/ensure-extension-memory-build.test.tstest/scripts/extension-boundary-selection.test.tstest/scripts/extension-test-plan.test.tstest/scripts/find-reusable-release-validation.test.tsx1245
Applied commit:
954c44fae595c51449f51813280b2e7c90128610. Test LOC +34 / -997 (net -963); declarations 153 → 88 (-65). Original coverage: statements 1,328 → 1,328; branches 747 → 746.src/agents/internal-events.test.tssrc/agents/internal-runtime-context.test.tssrc/agents/internal-session-effects.test.tssrc/agents/lanes.test.tssrc/agents/live-auth-keys.test.tssrc/agents/live-cache-regression-runner.test.tssrc/agents/live-model-filter.test.tssrc/agents/live-model-switch.test.tssrc/agents/live-model-turn-probes.test.tssrc/agents/live-test-helpers.test.tssrc/agents/local-model-lean.test.tssrc/agents/mcp-codex-tool-approval.test.tssrc/agents/mcp-http-fetch.test.ts