Repository navigation
ci(capability): treat a lone tests.rs directory as owner tests, and move router and read_limit_disclosure tests out of line (#15193) - #16677
EffortlessSteven wants to merge 8 commits into
Conversation
… their path checks at the new files (#15193) stop_reason_contract and gap_vocabulary skip their own file by path, so the skip now also covers the moved tests.rs. seam_cache's compaction test reads macro_item_names as a fixture that must contain tests, so it now reads the owner and its tests.rs together. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01YVdGzV3JdcCDM6STapqHBr
…-c92paw # Conflicts: # policy/inline-test-modules.txt
) Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01YVdGzV3JdcCDM6STapqHBr
…weep pin (#15193) The timeout-refusal schema binding in xtask's schema producer sweep pins a test name by reading limited_check.rs with include_str!. The test now lives in limited_check/tests.rs, so the pin and its authority text read that file. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01YVdGzV3JdcCDM6STapqHBr
…ove router and read_limit_disclosure tests out of line (#15193) check-capability-producers counted every directory under analysis/language/ as a language adapter. Moving router.rs's or read_limit_disclosure.rs's inline tests to <stem>/tests.rs created such a directory, and the gate then demanded a `lang-router` feature (#16657). A directory holding only tests.rs is now skipped. With the fix, the two owners move out of line and the gate passes; with the gate reverted, the same tree fails on both directories. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01YVdGzV3JdcCDM6STapqHBr
EffortlessSteven
left a comment
There was a problem hiding this comment.
SOURCE_REVIEW_READY for head 534db08
Inspected the full diff. read_inventory now skips a directory for which is_owner_test_dir is true: exactly one entry, named tests.rs, and a regular file. A read failure there propagates as an error rather than being ignored. The unit test covers the positive case and four alternates. The two owners keep #[cfg(test)] mod tests; with unchanged production code, and their bodies are apply output. The baseline loses both rows. The gate passes with the change and fails without it on the same tree; precommit exits 0.
Generated by Claude Code
|
Warning You have reached your daily quota limit. Please wait up to 24 hours and I will start processing your requests again! |
1 similar comment
|
Warning You have reached your daily quota limit. Please wait up to 24 hours and I will start processing your requests again! |
|
Warning Review limit reachedEnable usage-based reviews in Billing to review now. Otherwise, wait until the next included review is available.
Reviews can continue after your included limit without a manual trigger. An admin must approve usage-based billing. Next included review available in 52 minutes. View limit details
|
Requested by Steven · project thread
Summary
Batch 8 (#16657) failed
check-capability-producerson hosted CI. That gate counts every directory underanalysis/language/as a language adapter, so movingrouter.rs's orread_limit_disclosure.rs's inline tests to<stem>/tests.rsmade it demandlang-routerandlang-read_limit_disclosurefeatures. Both owners went to the tail. This PR:tests.rs(a module's out-of-line tests, not an adapter), with a unit test of the rule;mechanical_relocation.py applyoutput).Negative experiment on this tree: with the gate change reverted and the moves kept,
cargo xtask check-capability-producersfails on exactly those two directories ("adapter directory ... has no registered language with required_feature lang-router"). With the change, it passes.Source-of-truth Links
Proposal: #15217
Spec:
ADR:
Plan item:
Governing issue or accepted claim: #15193
Acceptance delta (one sentence): check-capability-producers ignores a directory holding only an out-of-line tests.rs, and router and read_limit_disclosure move their tests out of the published source.
Candidate Relationships
Candidate branch (GitHub PR head is authoritative after publication):
claude/project-thread-c92pawStack parent or prerequisite PR (if any): none
Proposed replacement of PR (if any; not yet accepted): none
Scope
Production delta:
#[cfg(test)]code moves). xtask's adapter inventory skips owner test directories.Evidence/support delta:
only_a_lone_tests_rs_directory_is_an_owner_test_dir:router/with only tests.rs is an owner test dir;python/with tests.rs and another file, a dir whosetests.rsis a directory, a dir withmod.rs, and an empty dir are not.Non-goals:
Proof
cargo test -p xtask --bin xtask capability_producers: 22 passed.cargo xtask check-capability-producerspasses with the change and fails without it (above).cargo xtask precommitexits 0 (same commit on base 53e06e9; the cherry-pick onto current main only re-resolvedpolicy/inline-test-modules.txt).Source review: REVIEW_READY 534db08
Claim Boundary
May claim: the gate no longer reads owner test directories as adapters; these two owners' tests leave the published source.
Must not claim: a measured
.cratesize change.Rollback
Plain revert.
Static Language Check
killed,survived,untested,proven, andadequate.CI Economics
Generated by Claude Code