Repository navigation
test(codex,discord,plugins,gateway,ui): remove low-value tests (batch d340) - #178773
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 SummaryThis comment shows the latest Codex review activity on this pull request.
ℹ️ About Codex in GitHubYour team has set up Codex to review pull requests in this repo. Reviews are triggered when you
Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings. |
|
Codex review: blocked before merge. What this changesThis PR consolidates repetitive test fixtures and assertions across Codex, Discord, agents, plugins, Gateway, infrastructure, and Control UI. Example: Cancel uninstalling Calendar Plus in the mobile plugin settings page.
Review scores
ProductKind: Test only · Worth it: Yes · Fix scope: Complete Merge readiness⛔ Blocked before merge - 1 item remains Keep open as useful maintainer-directed test cleanup; inspection found no concrete introduced defect. Priority: P3 Before merge
FindingsNone. Agent review detailsHow this fits togetherThe affected test suites supply synthetic requests, transport responses, and lifecycle events to production owners, then inspect their results and side effects. flowchart LR
A[Test fixtures] --> B[Production owners]
B --> C[Transport and storage boundaries]
C --> D[Observed results]
D --> E[Contract assertions]
E --> F[Hosted CI gate]
Technical reviewBest possible solution: Consolidate repeated setup through existing fixtures while preserving distinct contract assertions and completing the affected hosted checks. Do we have a high-confidence way to reproduce the issue? This PR reports repetitive test machinery rather than a product bug; no target code was executed during this read-only review. Is this the best way to solve the issue? Shared fixtures and parameterized cases fit the stated cleanup, and inspected authority, recovery, cancellation, and platform checks retain their observable contracts. AGENTS.md: found and applied where relevant. Codex review notes: model internal, reasoning medium; reviewed against 4b065f50d724. Provenance checked
TestingProof path: none. SecurityNone. EvidenceWhat I checked:
PR surfacePR surface statistics unavailable: the file list is incomplete. Review metrics
LabelsLabel 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 Reviewed October 20, 2026, 5:27 PM ET / 21:27 UTC. |
59eedcd to
22cbb7c
Compare
… d340) (openclaw#178773) * test(codex): deslop z0407 tests * test(codex): deslop z0408 tests * test(codex): deslop z0408 tests * test(codex): deslop z0408 tests * test(discord): deslop z0411 tests * test(discord): deslop z0411 tests * test(plugins): deslop z0410 tests * test(plugins): deslop z0410 tests * test(ui): deslop z0412 tests * test(ui): deslop z0412 tests * test(gateway): deslop z0413 tests * test(gateway): deslop z0413 tests * test(agents): deslop z0409 tests * test(agents): deslop z0409 tests * test(agents): deslop z0409 tests * test(gateway): deslop z0415 tests * test(gateway): further deslop z0415 tests * test(plugins): deslop z0414 tests * test(plugins): deslop z0414 tests * test(plugins): deslop z0414 tests * test(gateway): deslop z0416 tests * test(gateway): deslop z0416 tests * test(subagents): deslop z0401 tests * test(subagents): deslop z0401 tests * test(subagents): deslop z0401 tests * test(ui): deslop z0417 tests * test(ui): deslop z0417 tests * test(codex): deslop z0418 tests * test(codex): deslop z0418 tests * test(infra): deslop z0421 tests * test(plugins): retain uninstall cancellation coverage * test: preserve fixture types during consolidation * test: retain tuple and payload types in fixtures * test: preserve mock and callback contracts in cleanup * test: preserve request correlation and prune retired mock debt * test: retain fixture ordering and dispatch observations * test(ui): use native typed queries in settings fixture
Settlement on current main
Rebased onto
cd7b139617654304728df3cebfca4acc08e2eda2. Current diff: 87 files (+5,713 / -8,965; net -3,252), comprising 86 test/support files and 14 removed obsolete mock-baseline entries. No production changes. The earlier shard inventory and counts below describe the original replay, not this smaller settled diff.The old
check-lint-core-2failedtypescript(unbound-method)in untouchedsrc/flows/doctor-repair-flow.ts:73(run 39512420518). Main already fixed its receiver binding in5d80482379b3; this rebase incorporates that fix. The aggregate gate failed solely on the lint shard. The cancelled dispatch and context jobs completed their substantive steps successfully and had successful replacement jobs on the same head; no test failure was present.Preserved main's complete current versions instead of replaying conflicting old cleanup edits in:
extensions/discord/src/monitor/provider.lifecycle.test.tsextensions/discord/src/monitor/questions.test.tsextensions/discord/src/monitor/route-resolution.test.tsui/src/e2e/session-context-breakdown.e2e.test.tsui/src/e2e/session-context-meter.e2e.test.tsui/src/e2e/session-dashboard-active-panel.e2e.test.tsui/src/e2e/session-details-background-work.e2e.test.tssrc/gateway/server-methods/projects.test-support.tssrc/gateway/server-methods/push-preferences.worker.test.tsui/src/pages/plugins/settings-editor.browser.test.tsxui/src/pages/plugins/skill-preview.test.tssrc/gateway/server-methods/worktrees.authorization.test.tsui/src/app/connection-bootstrap.test.tsui/src/app/control-ui-chunking.test.tsui/src/app/gateway-presence-activity.test.tsFor
src/gateway/server.sessions.workspace-recovery.test.ts, retained only the first nonconflicting fixture/read-state consolidation; dropped the conflicting later rewrite so main's cleanup and current recovery scenarios survive. All 30 original campaign commits remain represented; no whole commit was deliberately skipped. Local validation remains CI-only: plain oxlint (byte-identical shared config/plugin), oxfmt check, and diff check pass. No tests, typechecks, remote boxes, longer timeouts, skips, or weakened assertions were used. Fresh exact-head hosted CI remains the execution proof.Independent settlement review completed over the whole final diff (two passes, P0–P2). Rejected three findings after source verification: (1)
gateway-plugin.ts:166runs the realvalidateDiscordProxyUrlbeforecreateNodeProxyAgent;bad-proxyis rejected by that validator, so the fallback does not rely on a throwing mock. (2)createPluginMetadataSnapshotFixturecallsrebasePluginMetadataSnapshotManifestRegistry, which binds the resulting snapshot togetPluginMetadataSnapshotCache(snapshot)inside the supplied cache scope (plugin-metadata-snapshot.ts:265); a second binding is redundant. (3) the bounded-continuity test retains the stronger exact assertion</conversation_context>\n\nCurrent user request:\n${params.prompt}, so losing the prompt already fails the test. No accepted actionable finding remains; no source changes were needed after review.What Problem This Solves
This batch consolidates repetitive test fixtures, setup, assertions, and table cases across Codex, Discord, plugins, Gateway, subagents, UI, and infrastructure. It does not change production code or UI behavior. Distinct authority, lifecycle, recovery, protocol, and platform checks are retained; hosted CI is the execution gate.
Replayed all 30 supplied campaign commits onto pinned main
bead2a8e542740f943fe57e8391e5e6c11e9773d. No whole commits were skipped.Evidence
node_modules/.bin/oxfmt --write <changed files>: exit 0.node_modules/.bin/oxlint -c .oxlintrc.json <changed TS/JS files>: exit 0.git diff --check bead2a8e542740f943fe57e8391e5e6c11e9773d: exit 0.openclaw/ci-gateselects and executes affected tests. No measured runtime/coverage improvement is claimed.createDiscordGatewayPlugincalls the realvalidateDiscordProxyUrlbefore the mocked agent factory, and that validator rejectsbad-proxy. The fallback remains exercised without duplicating validation inside the mock.git diff --check.check-test-types,check-test-types-core-1,check-test-types-core-2, andcheck-test-types-core-5. Corrected the named metadata-bearing message fixture, literal workspace-only params contract, explicit persisted-evidence assertion, readonly tuple inference, and concrete generic session-list options. No casts or production changes. Both focused correction reviews were scoped-clean at P0–P2; formatting, plain lint, and diff checks passed. The same run later exposedchecks-fast-baseline-ratchets(six partial-mock isolation contracts),check-lint-core-2(method binding and generic return annotation), andcheck-lint-extensions-3(string narrowing and Node HTTP listener return contract). Restored the fixture-specific isolation explanations, arrow binding, explicit return type, string checks, and original synchronous listener adaptation. Focused review was scoped-clean at P0–P2. - Run 39506489893 then exercised the runtime tests. Corrected actual-frame request-ID correlation in the CLI refusal fixture, initialized the model pin before setting its lock, and restored observation of steering at the dispatch callback rather than the attempted-request log. Each correction restored the original boundary and passed focused independent review, format, plain lint, and diff checks. The exact 14 obsolete closed-mock baseline entries were removed (no new allowances). Fresh-head CI is required; failed older-head jobs are not claimed as passing.Conflict resolution
For these seven files, retained current main's complete version and dropped the conflicting cleanup edits. This preserves newer lifecycle/cleanup behavior and avoids reviving retired APIs or older fixtures. Other file changes applied cleanly.
49c0ef4b2f3b:extensions/codex/src/app-server/run-attempt-one-shot-cleanup.test.ts49c0ef4b2f3b:extensions/codex/src/app-server/run-attempt-tools.test.ts49c0ef4b2f3b:extensions/codex/src/app-server/runtime-artifact-connection.test.ts49c0ef4b2f3b:extensions/codex/src/app-server/sandbox-exec-server.spawn-error.test.ts49c0ef4b2f3b:extensions/codex/src/app-server/service-tier.test.ts124cd68a33c5:extensions/discord/src/monitor/thread-bindings.discord-api.test.ts69d36c184a3d:src/gateway/server-methods/question.test-support.tsPer-shard replay inventory
Counts below compare the actual replayed diff with pinned main, including test-support files. Declaration counts are static counts of direct
it/testdeclarations and table declaration sites, not expanded table cases. Source shard reports predate follow-up commits and conflict drops, so their earlier totals differ. Every supplied shard report explicitly states coverage was not run under CI-only mode; there is no in-shard covered-statements/branches total to quote.z0401: files touched
src/agents/subagents/registry/subagent-registry-cleanup.test.tssrc/agents/subagents/registry/subagent-registry-completion.test.tssrc/agents/subagents/registry/subagent-registry-events.test.tssrc/agents/subagents/registry/subagent-registry-lifecycle-admission.test-support.tssrc/agents/subagents/registry/subagent-registry-lifecycle-cleanup.test-support.tssrc/agents/subagents/registry/subagent-registry-lifecycle.settle-yielded.test.tssrc/agents/subagents/registry/subagent-registry.session-failure.test.tssrc/agents/subagents/registry/subagent-registry.store.codec.test.tsz0407: files touched
extensions/codex/src/app-server/run-attempt-session-owners.test.tsextensions/codex/src/app-server/run-attempt-turn-start.provider-review.test.tsz0408: files touched
extensions/codex/src/app-server/thread-lifecycle-rooted.test-support.tsextensions/codex/src/app-server/thread-lifecycle-web-search.test-support.tsextensions/codex/src/app-server/thread-lifecycle.remote-hooks.test.tsextensions/codex/src/app-server/thread-lifecycle.restricted-continuation.test.tsextensions/codex/src/app-server/thread-lifecycle.user-mcp-servers.test-support.tsextensions/codex/src/app-server/thread-native.test-support.tsextensions/codex/src/app-server/thread-ownership.test.tsextensions/codex/src/app-server/transcript-mirror.admission.test.tsz0409: files touched
src/agents/agent-bundle-mcp-recovery.test-support.tssrc/agents/agent-bundle-mcp-retention.test.tssrc/agents/agent-bundle-mcp-runtime-config.cache.test.tssrc/agents/agent-bundle-mcp-runtime.sse-recovery.test.tssrc/agents/agent-bundle-mcp-runtime.stdio-recovery.test.tssrc/agents/agent-bundle-mcp-schema.test.tssrc/agents/agent-command-restart-recovery.test.tssrc/agents/agent-command.cancellation.test.tssrc/agents/agent-command.resolved-pin.test.tsz0410: files touched
src/cli/plugins-cli.cold-inspect.test.tssrc/cli/plugins-config.test.tssrc/cli/plugins-install-preflight.test.tssrc/cli/plugins-lifecycle-client.test.tssrc/cli/plugins-list-command.test.tssrc/cli/plugins-list-route-cold-imports.test.tssrc/cli/plugins-location-bridges.test.tssrc/cli/plugins-search-command.test.tsz0411: files touched
extensions/discord/src/monitor/presence-events.test.tsextensions/discord/src/monitor/provider.deploy.test.tsextensions/discord/src/monitor/provider.lifecycle.test.tsextensions/discord/src/monitor/provider.proxy.test.tsextensions/discord/src/monitor/questions.test.tsextensions/discord/src/monitor/route-resolution.test.tsextensions/discord/src/monitor/thread-bindings.worker.test.tsz0412: files touched
ui/src/e2e/session-context-breakdown.e2e.test.tsui/src/e2e/session-context-meter.e2e.test.tsui/src/e2e/session-dashboard-active-panel.e2e.test.tsui/src/e2e/session-dashboard.grant-failure.e2e.test.tsui/src/e2e/session-dashboard.test-support.tsui/src/e2e/session-details-background-work.e2e.test.tsui/src/e2e/session-github-preview.e2e.test.tsui/src/e2e/session-kinds.e2e.test.tsz0413: files touched
src/gateway/server-methods/progress-card-refresh.test.tssrc/gateway/server-methods/projects-recents.perf.test.tssrc/gateway/server-methods/projects-recents.test.tssrc/gateway/server-methods/projects.test-support.tssrc/gateway/server-methods/push-preferences.worker.test.tssrc/gateway/server-methods/request-authorization.test.tssrc/gateway/server-methods/sandbox-media.workspace-lifetime.test.tsz0414: files touched
ui/src/pages/plugins/plugins-consent.test.tsui/src/pages/plugins/plugins-page.mcp-auth.test.tsui/src/pages/plugins/plugins-runtime.e2e.test.tsui/src/pages/plugins/settings-editor.browser.test.tsxui/src/pages/plugins/skill-preview.test.tsz0415: files touched
src/gateway/server.agent-metadata-read-authority.test.tssrc/gateway/server.agent.rpc-contracts.test.tssrc/gateway/server.chat-dashboard-title-rollover.test.tssrc/gateway/server.sessions.archive-permissions.test.tssrc/gateway/server.sessions.automation-worker-placement.test.tssrc/gateway/server.sessions.create.sandbox-project.test.tssrc/gateway/server.sessions.thinking-e2e.test.tssrc/gateway/server.sessions.workspace-recovery.test.tsz0416: files touched
src/gateway/server-methods/users-github.test-support.tssrc/gateway/server-methods/validation.test.tssrc/gateway/server-methods/web-search.authority.test.tssrc/gateway/server-methods/web.gateway.test.tssrc/gateway/server-methods/web.login-lifecycle.test.tssrc/gateway/server-methods/web.start.test.tssrc/gateway/server-methods/workspace-fs.test.tssrc/gateway/server-methods/worktrees.authorization.test.tsz0417: files touched
ui/src/app/browser-link-routing.test.tsui/src/app/chat-submissions.test.tsui/src/app/connection-bootstrap.test.tsui/src/app/control-ui-chunking.test.tsui/src/app/control-ui-isolated-desktop-runtime.node.test.tsui/src/app/control-ui-readiness.test.tsui/src/app/gateway-page-activation.test.tsui/src/app/gateway-presence-activity.test.tsz0418: files touched
extensions/codex/src/app-server/run-attempt-continuity.test-support.tsextensions/codex/src/app-server/run-attempt.bounded-continuity.test.tsextensions/codex/src/app-server/run-attempt.computer-use.test.tsextensions/codex/src/app-server/run-attempt.hook-background-continuation.test.tsextensions/codex/src/app-server/run-attempt.media-lifetime.test.tsextensions/codex/src/app-server/run-attempt.native-background-outcome.test.tsextensions/codex/src/app-server/run-attempt.plugin-steering.test.tsextensions/codex/src/app-server/run-attempt.restricted-context-continuity.test.tsextensions/codex/src/app-server/run-attempt.skills.test.tsz0421: files touched
src/infra/windows-install-roots.test.tssrc/infra/windows-launcher-encoding.test.tssrc/infra/windows-process-census.test.tssrc/infra/windows-process-start.test.tssrc/infra/worker-cpu.test.tssrc/infra/worker-message-metrics.test.tsLatest correction: run 39509113889 rejected the one-use generic DOM helper under type-aware lint. Removed that wrapper and used the same native typed querySelector at each call site, preserving receiver, selector, element type and assertions. Focused review scoped-clean; oxfmt, plain oxlint and diff check passed. This final head still requires fresh hosted CI.