Repository navigation
Test the Ready issue rules in-process behind a seam for the search's reads - #371
Merged
Merged
Conversation
…reads (#370) The search reads each issue's candidate read and started check through an internal Reads seam, takes the time of the pass as a value, and hands each passed-over line to a caller-supplied sink. Unit tests drive the rules against an in-memory adapter, and the Pickup run end-to-end tests that only checked rule order or line wording are removed. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Merged
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
The Ready issue search now reads its outside facts through an internal seam. It takes the time of the pass as a value and hands each passed-over line to a sink.
ready::firstis unchanged, and so are its callers, the Pickup run and the Architect run.There are 15 unit tests in
src/ready.rs. They cover every rule and its line, the first-reason-that-applies order, and a Ticket whose Spec is or isn't ready, both above and below the Spec. They also cover the settle window at 9:59, 10:00 and 10:01 for each kind of shaping, a Spec whose Tickets are all closed (started and not started), and whether the Ready issue returned is a Spec. They assert the reads stay lazy: an issue passed over by its labels gets no read, and one passed over for its parent,base-fixor blockers gets no started check.Nine end-to-end tests in
tests/pickup_run.rsthat only checked rule order or line wording are deleted, and the unready-label test is cut down to one label. At least one kept end-to-end test still reaches each read: the labels, the parent, the blockers, the timeline (label and link shaping), the sub-issues' states, the Issue branch on origin and the pull request.Evidence
src/ready.rshad no unit tests. Its rules were checked only through the binary, against a fakegh.After:
cargo test --bin thirdshift ready::gives 15 passed. The fullcargo test,cargo clippy --all-targetsandcargo fmt --checkpass.Merge Danger
Door: two-way
The change is internal to one module, and nothing a user sees changes.
Blast Radius: contained
A mistake in the refactor would change which issue a Pickup run takes, or whether an Architect run gives way. The kept end-to-end tests cover each production read.
Unaddressed findings
Standards
Factsrepeats the fields ofCandidate. Collapsing them would mean addingCloneorDefaulttogithub::Candidateonly for tests. That widens a production type for no caller.Spec
a_started_issue_says_what_shows_it_was_started, and the rule order doesn't depend on which kind of start it was.now.Closes #370
🤖 Generated with Claude Code