Skip to content

test: share broad tooling routing assertions - #133971

Merged
steipete merged 1 commit into
mainfrom
codex/test-projects-shared-oracles
Aug 31, 2026
Merged

steipete merged 1 commit into
mainfrom
codex/test-projects-shared-oracles

Conversation

@steipete

@steipete steipete commented Aug 31, 2026 •

Copy link
Copy Markdown
Contributor

What Problem This Solves

The test-project planner’s broad-directory and flat-glob cases duplicate the same 60-line assertion body. Keeping two copies makes routing expectations easier to update inconsistently.

Why This Change Was Made

Use one two-row table with both original case names and inputs: test/scripts and test/scripts/*.test.ts. Each case still calls the real planner once and runs all eight original assertions. Exact owner-plan order, tooling chunk bounds, required inclusions/exclusions, uniqueness and the E2E forwarding plan remain unchanged. The separate routing suite is retained in full.

The glob case now runs immediately after the directory case, moving across five unchanged planning/watch cases. The suite’s existing hook and all configuration, fixtures and expected literals are unchanged.

User Impact

No user-facing or runtime behavior change. Tests have 61 fewer lines (+5/-66); production LOC is unchanged. This is a maintenance cleanup, not a measured execution-time improvement. No test selection, sharding, concurrency, deadline, retry or mock change.

Evidence

  • Normal repository-wrapper runs before and after pass all 450 cases: 367 in test-projects.test.ts and 83 in test-projects-routing.test.ts.
  • Full case names and statuses are preserved. Moving the glob case from zero-based index 176 to 171 accounts for the entire owning-file ordering difference; the routing file’s order is unchanged.
  • A shuffled repeat with seed 73 passes the same 450-case inventory. Verbose output confirms different execution order in both files.
  • Independent source and runtime-artifact reviews confirm both inputs, two planner calls and all 16 assertions remain. Complete planner/CLI owners, routing and admission siblings, config/classification owners and the installed Vitest registration/title formatter were inspected.
  • Codex autoreview completed with no actionable findings at its configured P0 threshold.

The full changed gate passed on Blacksmith Testbox, including test-root typechecking and script lint. The one-shot lease stopped successfully and its temporary checkout was removed. Exact-head CI run 33373158583 subsequently completed successfully. Fresh compositions at afd1 and landed main 22dcf4c both passed all 450 cases with identical per-file names, order and statuses. The latter preserves the canonical build-stamp ownership mapping from #133974. These focused runs are separate from the earlier full changed gate.

@clawsweeper

clawsweeper Bot commented Aug 31, 2026

Copy link
Copy Markdown
Contributor

🦞👀
ClawSweeper picked this up.

Pull request received. I will update this pull request when review starts.

@openclaw-barnacle openclaw-barnacle Bot added size: S maintainer Maintainer-authored PR labels Aug 31, 2026
@clawsweeper clawsweeper Bot added P3 Low-priority cleanup, docs, polish, ergonomics, or speculative work. rating: 🐚 platinum hermit Good normal PR readiness with ordinary maintainer review expected. status: 👀 ready for maintainer look ClawSweeper has no concrete contributor-facing blocker left for this PR. labels Aug 31, 2026
@clawsweeper

clawsweeper Bot commented Aug 31, 2026

Copy link
Copy Markdown
Contributor

Codex review: needs maintainer review before merge. Reviewed August 31, 2026, 4:37 AM ET / 08:37 UTC.

ClawSweeper review

What this changes

The PR replaces two duplicated broad test/scripts routing tests with one two-row parameterized Vitest test while retaining the same assertions for the directory and glob inputs.

Merge readiness

⚠️ Ready for maintainer review - 2 items remain

Keep open. This is a newly opened maintainer PR with a protected maintainer label; the introduced test-only refactor preserves two independently named target cases and their full routing assertions, with no actionable correctness finding.

Priority: P3
Reviewed head: d88c4c82900d6a187b763a352ba02e3a63e906eb

Review scores

Measure Result What it means
Overall readiness 🐚 platinum hermit (4/6) A focused, behavior-neutral test deduplication with source evidence that both routing inputs and assertions remain covered.
Proof confidence 🌊 off-meta tidepool Not applicable: This maintainer-authored PR changes only a test assertion structure; external contributor real-behavior proof is not required.
Patch quality 🐚 platinum hermit (4/6) No actionable review findings were identified.

Verification

Check Result Evidence
Real behavior Not applicable Not applicable: This maintainer-authored PR changes only a test assertion structure; external contributor real-behavior proof is not required.
Evidence reviewed 5 items Introduced change preserves both cases: The verified PR delta replaces the first duplicate body with a two-row table containing both original target strings; the shared callback retains the complete assertion body.
Planner owner boundary: The planner expands both broad script patterns before grouping and creates bounded tooling shards after classification; the retained assertions exercise the resulting plans for each table row.
Current-main comparison: Current main retains the pre-refactor test blob with the separate assertions, so this cleanup is not already implemented there.
Findings None None.
Security None None.

How this fits together

The test-project planner converts selected paths into ordered Vitest shard plans. The changed test protects broad script-target routing, including isolated, Docker, tooling, and E2E plan handling.

flowchart LR
  A[Broad script target] --> B[Test-project planner]
  B --> C[Target classification]
  C --> D[Vitest shard plans]
  D --> E[Routing assertions]
Loading

Before merge

  • Resolve merge risk (P1) - The supplied context omits the newest ClawSweeper bot comment and GitHub was unreachable during review; read any existing Rank-up moves before merge.
  • Complete next step (P2) - No repair is needed; normal maintainer merge gating should wait for exact-head CI and any existing review follow-up.
Agent review details

Security

None.

PR surface

Tests -61. Total -61 across 1 file.

View PR surface stats
Area Files Added Removed Net
Source 0 0 0 0
Tests 1 5 66 -61
Docs 0 0 0 0
Config 0 0 0 0
Generated 0 0 0 0
Other 0 0 0 0
Total 1 5 66 -61

Review metrics

Metric Value Why it matters
Production versus test delta production +0, tests +5/-66 (net -61) The branch removes duplicate test assertions without changing runtime or test-support behavior.

Merge-risk options

Maintainer options:

  1. Decide the mitigation before merge
    Keep the single table-driven assertion body, preserving both target rows and all plan-order, chunking, exclusion, uniqueness, and E2E-forwarding checks.
  2. Pause or close
    Do not merge this PR until maintainers decide whether the risk is worth taking.

Technical review

Best possible solution:

Keep the single table-driven assertion body, preserving both target rows and all plan-order, chunking, exclusion, uniqueness, and E2E-forwarding checks.

Do we have a high-confidence way to reproduce the issue?

Not applicable: this PR consolidates existing test coverage rather than reporting a product failure.

Is this the best way to solve the issue?

Yes. One parameterized test retains both distinct broad-target inputs and the full routing invariant, eliminating duplicate assertion maintenance.

AGENTS.md: found and applied where relevant.

Codex review notes: model internal, reasoning high; reviewed against 5f714efd47bd.

Labels

Label changes:

  • add P3: This is a low-risk test-maintenance refactor with no user-facing behavior change.
  • add rating: 🐚 platinum hermit: Overall readiness is 🐚 platinum hermit; proof is 🌊 off-meta tidepool and patch quality is 🐚 platinum hermit.
  • add status: 👀 ready for maintainer look: ClawSweeper has no concrete contributor-facing blocker left for this PR. Not applicable: This maintainer-authored PR changes only a test assertion structure; external contributor real-behavior proof is not required.

Label justifications:

  • P3: This is a low-risk test-maintenance refactor with no user-facing behavior change.
  • rating: 🐚 platinum hermit: Overall readiness is 🐚 platinum hermit; proof is 🌊 off-meta tidepool and patch quality is 🐚 platinum hermit.
  • status: 👀 ready for maintainer look: ClawSweeper has no concrete contributor-facing blocker left for this PR. Not applicable: This maintainer-authored PR changes only a test assertion structure; external contributor real-behavior proof is not required.

Evidence

What I checked:

Likely related people:

  • steipete: Suggested for follow-up; no historical authorship or introduction is verified. (role: unverified routing candidate; confidence: low)

Rank-up moves

Optional improvements that raise the rating; they are not merge blockers.

  • Let exact-head CI complete and read the latest ClawSweeper comment before merge.

Rating scale

Score Internal tier Crab rank Meaning
6/6 S 🦀 challenger crab Exceptional readiness
5/6 A 🦞 diamond lobster Very strong readiness
4/6 B 🐚 platinum hermit Good normal PR; ordinary maintainer review
3/6 C 🦐 gold shrimp Useful, but confidence is limited
2/6 D 🦪 silver shellfish Proof or implementation needs work
1/6 F 🧂 unranked krab Not merge-ready
N/A NA 🌊 off-meta tidepool Rating does not apply

Overall follows the weaker of proof and patch quality.
Shiny media proof means a screenshot, video, or linked artifact directly shows the changed behavior. Runtime, network, CSP, and security claims still need visible diagnostics.

Workflow

  • ClawSweeper keeps one durable marker-backed review comment per issue or PR.
  • Re-runs edit this comment so the latest verdict, findings, and automation markers stay together instead of adding duplicate bot comments.
  • A fresh review can be triggered by eligible @clawsweeper re-review comments, exact-item GitHub events, scheduled/background review runs, or manual workflow dispatch.
  • PR/issue authors and users with repository write access can comment @clawsweeper re-review or @clawsweeper re-run on an open PR or issue to request a fresh review only.
  • Maintainers can also comment @clawsweeper review to request a fresh review only.
  • Fresh-review commands do not start repair, autofix, rebase, CI repair, or automerge.
  • Maintainer-only repair and merge flows require explicit commands such as @clawsweeper autofix, @clawsweeper automerge, @clawsweeper fix ci, or @clawsweeper address review.
  • Maintainers can comment @clawsweeper explain to ask for more context, or @clawsweeper stop to stop active automation.

@steipete steipete self-assigned this Aug 31, 2026
@steipete
steipete merged commit 43e9a3d into main Aug 31, 2026
71 checks passed
@steipete
steipete deleted the codex/test-projects-shared-oracles branch August 31, 2026 11:44
@steipete

Copy link
Copy Markdown
Contributor Author

Merged via squash.

github-actions Bot pushed a commit to Desicool/openclaw that referenced this pull request Sep 1, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

maintainer Maintainer-authored PR P3 Low-priority cleanup, docs, polish, ergonomics, or speculative work. rating: 🐚 platinum hermit Good normal PR readiness with ordinary maintainer review expected. size: S status: 👀 ready for maintainer look ClawSweeper has no concrete contributor-facing blocker left for this PR.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant