test(core): add the RFC 0001 alias write-path red gate (RFC0001.12-.16) - #152
Conversation
Stubs the five §5 acceptance criteria for the operator-driven alias-index write path specified in RFC 0001 §6.7 (2026-06-07 amendment): durable alias_asserted/alias_retracted audit events on the §6.4 stream under the §3.4 WAL-before-ack barrier, the per-tenant alias-map projection, and resolves_to expansion by set membership. Per docs/verification.md §3 this crosses the specified → red gate: five #[ignore]'d unimplemented!() stubs, one per scenario, each carrying the §2.3 greppable doc-comment form so the spec↔test mapping resolves bidirectionally. Default cargo test stays green (outer loop); cargo test -- --include-ignored fires all five (inner loop / red signal). No implementation — the alias types/API land in following slices. Placed in ourios-core (tests/rfc0001_alias.rs): the alias events are new AuditPayload variants in ourios-core::audit and the per-tenant alias map is consumed by both ourios-miner (emission) and ourios-querier (resolves_to reads), so the shared crate is the home. The querier-side resolves_to DSL surface is RFC0002.9's separate gate. Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
|
Warning Review limit reached
More reviews will be available in 24 minutes and 49 seconds. Learn how PR review limits work. Your organization has run out of usage credits. Purchase more in the billing tab. ⌛ How to resolve this issue?After more reviews become available, a review can be triggered using the We recommend that you space out your commits to avoid hitting the rate limit. 🚦 How do rate limits work?CodeRabbit enforces hourly rate limits for each developer per organization. Our paid plans include higher PR review limits than trial, open-source, and free plans. In all cases, reviews become available again over time. During sustained high-volume PR review activity, CodeRabbit may temporarily slow when the next review becomes available. Please see our Fair Usage Limits Policy for further information. ℹ️ Review info⚙️ Run configurationConfiguration used: defaults Review profile: CHILL Plan: Pro Plus Run ID: 📒 Files selected for processing (1)
✨ Finishing Touches🧪 Generate unit tests (beta)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
|
@coderabbitai review |
✅ Action performedReview finished.
|
There was a problem hiding this comment.
Pull request overview
Adds the RFC 0001 alias-index write-path red-gate acceptance-test stubs (RFC0001.12–.16) to ourios-core, establishing the spec↔test traceability for the newly specified operator-driven aliasing model before implementation lands.
Changes:
- Introduces five
#[ignore]’dunimplemented!()integration-test stubs for RFC0001.12–.16 inourios-core. - Adds greppable scenario doc-comments (
/// Scenario RFC…+/// See docs/rfcs/… §5.) per the verification process.
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
What
The RED gate (
specified → red) for the RFC 0001 alias-index write path, just specified indocs/rfcs/0001-template-miner.md§6.7 (the 2026-06-07 operator-driven-alias amendment, #151) and enumerated as §5 scenarios RFC0001.12–.16.Five
#[ignore]'dunimplemented!()stubs incrates/ourios-core/tests/rfc0001_alias.rs, one per scenario. No implementation — this is purely the red gate; the alias types/API land in following slices.alias_asserted, WAL-before-ack §3.4) and the class{A, B}appears in the per-tenant map with derived canonicalA.resolves_to(A)andresolves_to(B)both expand to{A, B}(member↔representative symmetry);resolves_to(C)→{C}.[§3.7]: an alias inT1never affectsT2.alias_retracted, audited); canonical re-derived asmin; a one-member class is no longer an alias set.Verification (reproduced locally)
cargo fmt --all --check— cleancargo clippy --all-targets --all-features -- -D warnings— cleancargo test --all-features— green; the five stubs reportignored, nothing else changescargo test -p ourios-core --test rfc0001_alias -- --include-ignored— exits non-zero, all fiveunimplemented!()fire (the inner-loop red signal perdocs/verification.md§3)Each stub carries the §2.3 greppable doc-comment form (
Scenario RFC0001.<n> — …+See docs/rfcs/0001-template-miner.md §5.) so the spec↔test mapping resolves bidirectionally.Placement
crates/ourios-core/tests/rfc0001_alias.rs. The alias events are newAuditPayloadvariants inourios-core::audit, and the per-tenant alias map is consumed by bothourios-miner(emission) andourios-querier(resolves_toreads), so the shared crate is the natural home. The querier-sideresolves_toDSL surface is RFC0002.9's separate gate (crates/ourios-querier/tests/rfc0002_dsl.rs).Implementation follows in slices
alias_asserted/alias_retracted) + the per-tenant alias-map projection + the operator assertion/retraction APIresolves_toexpansion wired to the map (closes RFC0002.9)🤖 Generated with Claude Code