Skip to content

test: consolidate model and plugin metadata fixtures - #133570

Merged
steipete merged 1 commit into
mainfrom
codex/130706-test-consolidation
Aug 30, 2026
Merged

steipete merged 1 commit into
mainfrom
codex/130706-test-consolidation

Conversation

@steipete

@steipete steipete commented Aug 30, 2026 •

Copy link
Copy Markdown
Contributor

Related: #130706

What Problem This Solves

Repeated model-normalization and plugin-metadata fixtures make tests harder to maintain and inflate the larger Gateway performance refactor.

Why This Change Was Made

Share identical index and manifest constructors through the existing test-support module, reuse the legacy-model normalizer, and table the two visibility-policy variants. Keep the original test names, assertions, option omission, and empty command aliases in provider-only fixtures.

This is an independent extraction from #130706. It contains no runtime ownership changes; the Gateway CPU report (#130324) remains unresolved.

User Impact

No production behavior change. Production LOC: +0/-0. Tests: +53/-193; test support: +50/-0. Total: four files, +103/-193, 90 fewer lines. No dependency or documentation changes remain.

Evidence

  • The same 105 cases in five complete files pass before and after, with identical names and per-file order. All 161 assertion expressions in the three changed test files are preserved; both metadata suite bodies are unchanged.
  • After rebasing onto main, the full cohort including upstream's six docs tests passes: 111 tests across six complete files. The four-file cleanup patch is byte-identical to the earlier reviewed version.
  • The final proportional changed-file gate passes. Fresh managed Codex branch review against the pinned main base returned no findings at its P0 scope.
  • Raw/resolved persisted-model tests remain. No timeout, mock boundary, or assertion was weakened. A full product build/live run is not needed for this test-only extraction.

The temporary docs-navigation correction was dropped during rebase because upstream now derives release expectations from navigation. The docs test matches main exactly and is outside this PR's final diff. The earlier Matrix crypto native download failure was an installation/network failure; no dependency workaround was added.

The reduction is measured against this PR's pinned main base. It overlaps cleanup already present in #130706 and is not additional savings on top of the earlier cleanup tally.

@clawsweeper

clawsweeper Bot commented Aug 30, 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 agents Agent runtime and tooling size: M maintainer Maintainer-authored PR labels Aug 30, 2026
@steipete
steipete marked this pull request as ready for review August 30, 2026 21:46
@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 30, 2026
@clawsweeper

clawsweeper Bot commented Aug 30, 2026 •

Copy link
Copy Markdown
Contributor

Codex review: needs maintainer review before merge. Reviewed August 30, 2026, 7:13 PM ET / 23:13 UTC.

ClawSweeper review

What this changes

The branch centralizes repeated model-normalization and plugin-metadata test fixtures, while preserving each suite’s existing assertions and provider-specific metadata shape.

Merge readiness

⚠️ Ready for maintainer review - 2 items remain

No blocking correctness finding was identified in the exact introduced test-only diff. This PR remains open for explicit maintainer handling because it is member-authored, carries the protected maintainer label, and the captured exact-head check rollup is incomplete.

Priority: P3
Reviewed head: 95c04691ecfc6889b6050b9dd2b91aabf4fe16bb
Owner decision: Required. See Decision needed.

Review scores

Measure Result What it means
Overall readiness 🐚 platinum hermit (4/6) The patch is a focused, production-neutral fixture extraction with no identified correctness or security defect.
Proof confidence 🌊 off-meta tidepool Not applicable: This member-authored test-only cleanup does not change user-visible runtime behavior; review relies on fixture and contract preservation rather than live behavior proof.
Patch quality 🐚 platinum hermit (4/6) No actionable review findings were identified.

Verification

Check Result Evidence
Real behavior Not applicable Not applicable: This member-authored test-only cleanup does not change user-visible runtime behavior; review relies on fixture and contract preservation rather than live behavior proof.
Evidence reviewed 6 items Exact introduced surface: The verified merge-base-to-head patch changes four test or test-support files only; it has no runtime, dependency, workflow, configuration, or documentation hunk.
Fixture contract preservation: The shared index and manifest helpers retain the snapshot suite’s default command alias, while the provider-runtime suite explicitly clears that alias before its assertions.
Model-policy variants: The table preserves distinct default and explicit-normalization assertions; the conditional spread omits the option for the default case rather than passing an explicit undefined value.
Findings None None.
Security None None.

How this fits together

Agent model selection uses plugin metadata to normalize configured and persisted model references, while plugin runtime paths reuse lifecycle-owned metadata snapshots. This PR changes the test fixtures that verify those contracts, not the runtime owners themselves.

flowchart LR
  Config[Agent configuration] --> Selection[Model selection]
  Metadata[Plugin metadata snapshot] --> Selection
  Fixtures[Shared test fixtures] --> ModelTests[Model selection tests]
  Fixtures --> SnapshotTests[Plugin snapshot tests]
  ModelTests --> Contracts[Runtime contract coverage]
  SnapshotTests --> Contracts
Loading

Decision needed

Question Recommendation
Should a maintainer accept this focused test-only cleanup after the exact-head required check rollup completes? Accept after checks: Merge the focused fixture consolidation once the exact-head required checks complete successfully.

Why: Protected maintainer-labelled, member-authored work requires explicit maintainer handling even though no patch defect was found.

Before merge

  • Complete next step (P2) - The remaining action is protected maintainer review and completion of the exact-head check rollup, not an automated repair.
Agent review details

Security

None.

PR surface

Source +50, Tests -140. Total -90 across 4 files.

View PR surface stats
Area Files Added Removed Net
Source 1 50 0 +50
Tests 3 53 193 -140
Docs 0 0 0 0
Config 0 0 0 0
Generated 0 0 0 0
Other 0 0 0 0
Total 4 103 193 -90

Review metrics

Metric Value Why it matters
Production versus test LOC production +0/-0; tests +53/-193; test support +50/-0 Fifty shared fixture lines replace 193 duplicated test lines without changing a production owner.

Merge-risk options

  • The captured check rollup is incomplete, so this review cannot establish that all required checks are green for the exact head.

Maintainer options:

  1. Decide the mitigation before merge
    Retain the shared test-support constructors and land the focused cleanup once the exact-head required checks complete and a maintainer accepts it.
  2. Pause or close
    Do not merge this PR until maintainers decide whether the risk is worth taking.

Technical review

Best possible solution:

Retain the shared test-support constructors and land the focused cleanup once the exact-head required checks complete and a maintainer accepts it.

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

Not applicable: the PR reorganizes test fixtures and does not report a user-facing defect to reproduce.

Is this the best way to solve the issue?

Yes. The shared helpers serve the two equivalent metadata suites, and the provider suite preserves its intentionally alias-free fixture after construction.

AGENTS.md: found and applied where relevant.

Codex review notes: model internal, reasoning high; reviewed against 6cf8e884edbd.

Labels

Label justifications:

  • P3: This is focused test-maintenance cleanup with no production 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 member-authored test-only cleanup does not change user-visible runtime behavior; review relies on fixture and contract preservation rather than live behavior proof.

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)
  • vincentkoc: Suggested for follow-up; no historical authorship or introduction is verified. (role: unverified routing candidate; confidence: low)

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.

History

Review history (2 earlier review cycles)
  • reviewed 2026-08-30T21:52:00.824Z sha c0933b8 :: needs maintainer review before merge. :: none
  • reviewed 2026-08-30T22:59:33.864Z sha 95c0469 :: needs maintainer review before merge. :: none

@steipete
steipete force-pushed the codex/130706-test-consolidation branch from 85a0762 to 95c0469 Compare August 30, 2026 22:53
@steipete
steipete merged commit 621ef9e into main Aug 30, 2026
173 checks passed
@steipete
steipete deleted the codex/130706-test-consolidation branch August 30, 2026 23:14
@steipete

Copy link
Copy Markdown
Contributor Author

Merged via squash.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

agents Agent runtime and tooling 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: M 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