diff --git a/docs/rfcs/0028-build-feedback-program.md b/docs/rfcs/0028-build-feedback-program.md index 54cf4739f..9c104d4b8 100644 --- a/docs/rfcs/0028-build-feedback-program.md +++ b/docs/rfcs/0028-build-feedback-program.md @@ -1,7 +1,7 @@ --- rfc: 0028 title: Build-feedback program — test-harness consolidation and workspace decomposition -status: drafted +status: specified author: Jens Holdgaard Pedersen drafting-assistance: Claude created: 2026-07-06 @@ -129,12 +129,69 @@ runner-agnostic). CI keeps the exact same suite inventory. ## 5. Acceptance criteria -Written at the `specified` gate (docs/rfcs/README.md lifecycle). -Proposed scenarios accompany the drafting PR for sign-off. +Scenario ids `RFC0028.`. Maintainer sign-off: 2026-07-06 (the +proposed scenarios accompanied the drafting PR, #383). + +> **Scenario RFC0028.1 — consolidation preserves the test +> inventory.** Given the pre-consolidation +> `cargo test -p -- --list` inventory, When the crate's +> harness consolidation lands, Then the post-consolidation inventory +> lists the same set of tests, differing only by the harness's +> module-path prefix (`--list` prints test names as module paths; a +> file moving under `tests/it/` gains its module segment), And no +> test body changed in the move. + +> **Scenario RFC0028.2 — isolation-sensitive tests stay isolated.** +> Given the slice-1 inventory of tests requiring process isolation +> (process-global installers, env-mutating, hardware-gated), Then +> those tests are not merged into a shared harness — they stay in +> dedicated integration-test binaries (grouped where they can safely +> share one), each annotated with the reason it cannot join the +> harness. + +> **Scenario RFC0028.3 — the probe set improves.** Given the epic +> #382 probe set re-run after slices 1–2 — on the same machine and +> under the same conditions the baseline was captured (warm +> workspace, same toolchain; environment recorded next to the +> numbers in the epic) — Then the incremental-edit probe — +> `touch crates/ourios-core/src/lib.rs` (an mtime-only update, +> exactly as the epic's baseline measured it) followed by +> `cargo test -p ourios-querier --no-run` — drops below 30 s, And +> full-workspace `cargo test` wall time drops by at least 30% +> against the epic's baseline. + +> **Scenario RFC0028.4 — the core split is behavior-free.** Given +> the `ourios-config` extraction, When the full workspace suite +> runs, Then results are identical pre/post split, And a +> `MinerConfig` edit no longer rechecks type-only core consumers. + +> **Scenario RFC0028.5 — CI parity.** Given the consolidated +> harnesses (and nextest, if slice 5 adopts it), Then CI runs the +> identical suite inventory and stays green. ## 6. Testing strategy -Follows §5 at the `specified` gate. +Inventory diffs are the mechanism for RFC0028.1/RFC0028.5's name +half, and the PR diff is the mechanism for its no-body-change half: +a consolidation PR is restricted to file moves plus the mechanical +harness scaffolding (`tests/it/main.rs` `mod` lines, import-path +adjustments); the reviewer rejects any hunk inside a test function +body. For RFC0028.1's inventory, a +`cargo test -p -- --list` snapshot (scoped to the crate +being consolidated, matching RFC0028.1) is captured in each +consolidation +PR's description and diffed against the post-move run — the +reviewer checks the diff is a pure path-prefix rename. RFC0028.2 is +a committed list (the harness-exempt binaries and their reasons, in +the consolidating crate's `tests/` README or module docs). +RFC0028.3's probe numbers are recorded in epic #382 alongside the +baseline so the before/after is one table. RFC0028.4 is the full +suite run plus a +recheck-set spot check: a whitespace-only edit inside the +`MinerConfig` definition (`crates/ourios-core/src/config.rs` today; +its new home after the split), then `cargo build -vv` on a +type-only core consumer, asserting the build reports the consumer +`Fresh` (no `Compiling`/`Dirty` line for it). ## 7. Open questions