mirror of
https://relay.ngit.dev/npub15qydau2hjma6ngxkl2cyar74wzyjshvl65za5k5rl69264ar2exs5cyejr/ngit-grasp.git
synced 2026-10-05 15:08:24 +00:00
The archive service tests started ngit-grasp with a private helper that reserved a port, released the reservation, and then spawned the relay. Between the release and the child's bind, another test in the same process, or another test binary, could bind the same port. The failure surfaced under concurrent load as "connection refused" after readiness, because the readiness probe had reached whichever process won the port. Use `TestRelay::start_with_archive_grasp_services`, which transfers the bound listener into the child through the test listener handoff and never releases the address. The tests keep their announcement and repository assertions and now stop the relay through the fixture, which also captures its log. This removes the last `PortReservation::release` call in the test suite. Validation: measured against master with the same binaries, 20 unloaded runs and 30 samples as three concurrent instances under CPU spinners; see the pull request description. Assisted-by: Claude Fable 5.1 Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>