Skip to content

[TST-E7] test: SDK test helpers and fixtures live in the slice that uses them - #402

Merged
Blind-Striker merged 2 commits into
masterfrom
test/tst-e7-3a-sdk-slices
Oct 16, 2026
Merged

Blind-Striker merged 2 commits into
masterfrom
test/tst-e7-3a-sdk-slices

Conversation

@Blind-Striker

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

Copy link
Copy Markdown
Collaborator

📝 Description

What does this PR do?
It moves OpenCode.Sdk.Tests helpers and embedded fixtures out of the project root and into the slice whose code uses them, as testing-style.md §1 already says. It is moves only: no test body, assertion or helper behaviour changes.

Part of TST-E7 (step 3a, the SDK half; the Tools half follows as a separate PR).

🔄 Type of Change

  • 🧪 Test improvements

🎯 Protocol & API Surface

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

🧪 Testing

Clone baselines. The second commit carries only the tests baseline's own delta: 16 using-header fingerprints added and 4 removed, re-paired because the moved files' using blocks now pair differently. One fingerprint (0bb96000…) has count 2. No method-body pair was baselined. The delta is checked against the live clone set: the baseline regenerated from an empty fingerprint set at this head has 811 fingerprints for 823 clones. Every added fingerprint is in it with its exact count, and no removed one is.

Master's other stale entries are left for TST-E0c, which makes stale entries fail the gate (#384). The exception is src.baseline.json's 694a3508…: the moves commit removes it. It is stale on master (this PR touches nothing under src/), and TST-E0c removes the same entry.

Review. A fresh read-only review re-checked:

  • the helpers' ownership;
  • every moved resource's include and LogicalName;
  • the .editorconfig sections;
  • stale path references;
  • the baseline delta.

Its §3 note and its PathCommandShim defect are fixed in this head. Its Gate finding (Transport-only at d13d9833) no longer holds after #398, so Gate stays at root, as above.

Implementer's run. The implementer's whole-project run showed 38 ServiceFixture failures. They came from a narrow build that skipped packaging, not from a defect; the solution-build run below passes them.

✅ Completion Gate

Local check (quality-gates.md) on head b960774b, base cde7e254, idle host. 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
  • OpenCode.Sdk.Tests (all but ServiceElection/NativeAot): 8179, 0 failed
  • OpenCode.Sdk.Tools.Tests (all but NativeAot): 1794, 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 (the ledger rows moved with their files)
  • No tests skipped, weakened, or deleted to make the suite pass

@Blind-Striker
Blind-Striker added this pull request to the merge queue Oct 16, 2026
@github-merge-queue
github-merge-queue Bot removed this pull request from the merge queue due to a conflict with the base branch Oct 16, 2026
A helper or fixture that one slice uses moves into that slice's Support/ or Fixtures/ folder; one that several slices use stays at the project root. Embedded fixtures keep their old resource names through explicit LogicalName metadata, and the two upstream oracle scripts follow their fixture folders. Only namespaces, the imports that follow, item metadata, editorconfig section paths, guard and ledger paths, and path relays change. Gate and PathCommandShim, whose only cross-slice mentions were comments, go to Transport and the Launcher.
The moved helpers' consumers import their slice's Support namespace, so using-header pairs re-pair. Each added fingerprint is a header clone; the ignore-using change removes them.
@Blind-Striker
Blind-Striker force-pushed the test/tst-e7-3a-sdk-slices branch from 137c605 to b960774 Compare October 16, 2026 22:45
@Blind-Striker
Blind-Striker added this pull request to the merge queue Oct 16, 2026
Merged via the queue into master with commit 78d47a1 Oct 16, 2026
12 checks passed
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