Skip to content

[TST-E3] test: the emission and ingestion tests that only read the pinned spec share its one binding - #438

Merged
Blind-Striker merged 1 commit into
masterfrom
test/tst-e3a-pinned-consumers
Oct 17, 2026
Merged

Blind-Striker merged 1 commit into
masterfrom
test/tst-e3a-pinned-consumers

Conversation

@Blind-Striker

@Blind-Striker Blind-Striker commented Oct 17, 2026 •

Copy link
Copy Markdown
Collaborator

📝 Description

What does this PR do?
It is the third PR of TST-E3's first half. Eight emission and ingestion test classes that only read the pinned spec now take it from the session-shared Support/PinnedBinding fixture that #434 added, instead of ingesting or binding it themselves:

Class Reads
Generator/Emission/ExperimentalSurfaceEmissionTests Plan (its diagnostic variant is still a local with copy)
HandWrittenDoorRemarksTests Document
HandWrittenExperimentalDoorTests Document, Curation
HandWrittenTransportTableTests Document (both table rows kept)
OptionalConverterEmitterTests Plan.Models (its private helper is now synchronous, since nothing is awaited)
SessionScopedEventEmissionTests Plan
SourceEmitterTests Plan (the full union and registry comparisons stay full)
Generator/Ingestion/PinnedSpecSmokeTests Document, for its ordinary landmark tests

The determinism test stays independent. PinnedSpecSmokeTests' determinism test still ingests twice through its own helper, and now carries a comment saying why: comparing a cached result with itself proves nothing.

Pinned ingestions for these classes go from 22 to 3 per session: the shared initialization plus the two deliberate determinism ingestions. All 40 test names, 140 assertions and 4 argument rows are unchanged, and no test mutates the shared objects.

The files GEN-E3 is editing, PinnedBinding, BindingTestHost, BindingScenarioData and SpecScenario are unchanged.

🔄 Type of Change

  • 🧪 Test improvements

🎯 Protocol & API Surface

  • No change to the public API surface
  • Nothing under external/, spec/ or src/ was touched

🧪 Testing

  • Ingestion count: measured with temporary instrumentation in the implementer's worktree, then removed: 22 completed ingestions before, 2 plus the fixture's 1 after.
  • Harness evidence: the dispatch harness ran the RepositoryGates guards (93/0), verify-clones (0 new) and the whole Tools.Tests project under [(Category!=Packaging)&(Category!=NativeAot)] (1991/0, exit 0) on the committed tree.
  • Review: a fresh read-only review found no defects, out-of-scope changes or notes. It traced every adopter. The diagnostic variant uses with, the emission only enumerates Plan.Models, the determinism helper is untouched, and the seven migrated smoke tests inspect ingestion landmarks, not repeated-execution behaviour.
  • Rebase: written on [TST-E3] test: the pinned spec is bound once per session for the binding tests that only read it #434's head and rebased onto its merge, with no conflict.

✅ Completion Gate

Local check (quality-gates.md) on head 4630df90, base 321ce2fc. Every step's own exit code was read:

  • slopwatch: zero findings
  • dotnet build --configuration Release: 0 warnings, 0 errors
  • dotnet format whitespace / dotnet format style --severity warn: no changes
  • verify-clones: passed, 0 new (tests 5.52%)
  • OpenCode.Sdk.Tools.Tests (all but NativeAot): 2004, 0 failed
  • OpenCode.Sdk.Tests (all but ServiceElection/NativeAot): 8390, 0 failed

The host runs Bun 1.4.3, a maintainer-named off-pin host (OPENCODE_SDK_TESTS_BUN_MISMATCH=allow); the pin is 1.4.2.

✅ Code Quality Checklist

  • No new suppression
  • No tests skipped, weakened, or deleted to make the suite pass

View with [code]smith Autofix with [code]smith
Need help on this PR? Tag @codesmith-bot with what you need.

… share its one binding

TST-E3 first half, PR 3. Eight emission and ingestion test classes read Document, Curation or Plan from the session-shared PinnedBinding instead of ingesting or binding the pin themselves (22 ingestions per session become 3: the fixture plus PinnedSpecSmokeTests' two deliberately independent determinism ingestions, now commented). No assertion, test name or argument row changes.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant