Problem
crates/peryx-test-support/src/lib.rs:823 and :852 are the last two uncovered lines in that crate, and both sit in Node, the live-process harness. One is an HTTP-refused arm, the other a second startup-wait arm.
Node's fields are private and no unit test constructs it, so neither line can be reached from peryx-test-support's own tests. Covering them needs a spawned binary.
Why this is separate
Reaching these two lines means adding a live-process test, and per #990 / #992 any such test has to be a submodule of the availability binary rather than a standalone tests/*.rs — otherwise --all-features runs it in the fast test job, which has no toxiproxy, and it races and fails there.
So the cost is a live-process test living in another crate's binary, to cover two lines, using machinery peryx-test-support does not otherwise need for its own tests. That is a different kind of work from the rest of #2166, which is why it is filed on its own rather than folded into that PR.
Required change
Decide between two dispositions, and say which in the PR:
- Cover them with a live-process test placed as a submodule of the
availability binary, driving a refused HTTP connection and a startup wait that needs a second poll.
- Restructure
Node so the two arms are reachable without a spawned process — for instance by making the wait and the probe take an injectable transport, the way claimed(candidates: impl Iterator<Item = u16>) already lets a test drive port exhaustion without touching the real band.
Prefer the second if a seam exists that production code would accept. Establish which before writing.
Acceptance criteria
- Both lines are covered, or removed if either turns out to be unreachable, with the citation either way.
- No new standalone
tests/*.rs drives a live process.
- The fast test job stays green with
--all-features, and no new test depends on toxiproxy outside the availability binary.
Boundary
Only these two lines and whatever seam they need. Do not restructure the rest of Node, and do not move existing live-process tests.
Problem
crates/peryx-test-support/src/lib.rs:823and:852are the last two uncovered lines in that crate, and both sit inNode, the live-process harness. One is an HTTP-refused arm, the other a second startup-wait arm.Node's fields are private and no unit test constructs it, so neither line can be reached fromperyx-test-support's own tests. Covering them needs a spawned binary.Why this is separate
Reaching these two lines means adding a live-process test, and per #990 / #992 any such test has to be a submodule of the
availabilitybinary rather than a standalonetests/*.rs— otherwise--all-featuresruns it in the fast test job, which has no toxiproxy, and it races and fails there.So the cost is a live-process test living in another crate's binary, to cover two lines, using machinery
peryx-test-supportdoes not otherwise need for its own tests. That is a different kind of work from the rest of #2166, which is why it is filed on its own rather than folded into that PR.Required change
Decide between two dispositions, and say which in the PR:
availabilitybinary, driving a refused HTTP connection and a startup wait that needs a second poll.Nodeso the two arms are reachable without a spawned process — for instance by making the wait and the probe take an injectable transport, the wayclaimed(candidates: impl Iterator<Item = u16>)already lets a test drive port exhaustion without touching the real band.Prefer the second if a seam exists that production code would accept. Establish which before writing.
Acceptance criteria
tests/*.rsdrives a live process.--all-features, and no new test depends on toxiproxy outside theavailabilitybinary.Boundary
Only these two lines and whatever seam they need. Do not restructure the rest of
Node, and do not move existing live-process tests.