test(core,plugins): remove low-value tests (batch d118) (#162138)
test(core,plugins): remove low-value tests (batch d118) (#162138) * test(scripts): deslop t0421 tests * test(node-host): deslop t0420 tests Remove repeated policy-drift inputs, generic route checks, and replays of pager, wrapper-depth, and approval-plan owner tests. Consolidate durable approval fixtures and lifecycle cleanup; infer mock result types instead of casting partial copies of production contracts. Preserve Vitest routing. The 50% campaign target is not reached. Retention ledger below names each remaining case (table rows expanded), using the requested rules: 1 = unique covered execution path; 2 = historical regression; 3 = distinct security boundary. No unrelated behaviors were combined to reduce counts. - Native cwd refusal: 2, d88e10a752f, preserve preparation-refusal classification. - Lost companion response: 3, disabled fallback must never replay locally. - Already-cancelled command: 1, entry cancellation return. - Cancelled local completion: 1, post-run cancellation return and signal forwarding. - Pending Mac cancellation: 1, post-bridge cancellation return without replay/publication. - Medium-risk auto review: 2, 3b26947669f, ordinary audit-related argv must reach review and execution. - Auto review without a plan: 3, unbound commands cannot obtain model authority. - Login-shell startup: 3, startup effects cannot bypass review through a forged plan. - Reviewer asks: 1, defer-to-human switch branch. - Reviewer denies: 3, explicit model refusal cannot execute. - Approved env wrapper argv: 3, preserve approved positional execution semantics locally and over the bridge. - Transparent versus semantic env wrappers: 3, only transparent carriers may unwrap into an allowlisted executable. - Nested safe-bin chains: 3, bind rewritten shell payloads to canonical safe-bin paths. - PowerShell wrappers: 1, non-POSIX transport must bypass POSIX rewriting. - PATH-token allowlist execution: 3, launch the canonical approved executable rather than a mutable PATH alias. - Live policy revocation at commit: 3, recheck authority after awaited persistence before real launch. - Live policy revocation at callback: 3, the launch adapter must recheck immediately before spawning. - Live policy unchanged at callback: 3, positive control proves authorized real execution succeeds. - Unbindable auto executable identity: 3, model review cannot authorize an unbound dispatch chain. - Human executable identity drift at commit: 3, changed executable resolution invalidates the approved command. - Script drift after commit: 3, recheck mutable operands after the persistence await. - Runtime script binding at dispatch: 3, reject changed operands and omitted required bindings. - Relative skill-bin invocation: 3, skill trust cannot authorize an arbitrary relative executable. - Unsafe environment inputs: 3, block dangerous overrides, argv assignments, and invalid env keys. - Shell executable env allowlist: 3, filter shell environments even without an inline payload. - Revoked rule during allow-always commit: 3, do not resurrect revoked authority through grant persistence. - Unprompted ask tightening during commit: 3, current-policy authority must not survive a newly required prompt. - Auto-review ask tightening during commit: 3, forwarded model authority remains bound to its prepared policy snapshot. - Exact-plan forwarded strict inline review: 3, authenticated one-shot authority remains scoped to its bound plan. - Unavailable screen recording: 3, deny before execution or durable grant mutation. - Tightened timeout fallback policy: 3, reevaluate fallback authority at commit. - Fallback without canonical plan: 3, reject unbound fallback provenance. - Explicit approval without canonical plan: 3, reject unbound explicit authority. - Delayed approval without policy snapshot: 3, require the prepared policy identity. - Allowlist revocation after prepare: 3, reject stale authority before committing. - Mixed fallback and explicit provenance: 3, refuse contradictory authority sources. - Durable allowlist timeout fallback: 3, positive control for an exact durable grant. - Revoked durable timeout source: 3, source downgrade removes fallback authority. - Mac fallback bridge: 3, forward fallback provenance without inventing explicit approval. - Fallback versus strict inline review: 3, timeout fallback cannot satisfy mandatory review. - Unknown approval provenance: 3, reject unsupported authority markers. - Benign awk durable grant: 3, a file-based grant must not reopen inline programs. - Make inline grant: 3, explicitly approved runtime payloads remain one-shot. - Windows cmd transport: 3, unwrap transport before deciding shell approval requirements. - Windows durable trust downgrade: 3, revalidate the exact durable source at commit. - Durable cwd replacement: 3, directory identity remains bound through execution. - Safe builtin with redundant exact grant: 1, builtin authorization must survive revocation of an unused grant. - Socket response loss: 2, adf5c673821, real completed execution must never replay after its reply is lost. Measurements and validation: - Executed tests: 90 -> 48, down 46.67%. - Shard test LOC: 3431 -> 2045, down 40.40%. - Covered statements: 357 -> 354 (-0.84%). - Covered branches: 438 -> 435 (-0.68%). Functions: 34 -> 34. - Only invoke-system-run-plan.ts drops coverage: 3 statements, 3 branches. These are removed preparation-only probes; no source file drops >5 statements. - Both Vitest coverage groups succeeded; no groups were excluded. - Blacksmith Testbox: both shard files pass (47 infra + 1 unit tests). Final file durations: 2.80s infra; 1.95s unit. - check:changed passes, including core-test types, boundary checks, all dead-export scans, and type-aware lint (0 warnings, 0 errors). - Local oxfmt, plain oxlint, and git diff --check pass. - No production or shared test-support changes; no bugs or flakes found. - Proof workflow: https://github.com/openclaw/openclaw/actions/runs/36738903333 * test(ai): deslop t0414 tests * test(commands): deslop t0423 tests * test(google): deslop t0416 tests * test(board): deslop t0409 tests * test(infra): deslop t0410 tests * test(gateway): deslop t0429 tests * test(doctor): deslop t0422 tests * test(signal): deslop t0426 tests * test: retain distinct regressions in batch d118
评论
?
参与讨论