TestCodexOwnSignInTellsWhereItsTimeWent went red in a full run at
3438b7bd9 on the magpie-desktop WSL box (Linux, busy):
timing {... Send:4 Wait:196.9 Head:202.1} for a 200ms hold
The fake backend starts its hold once it has read the body, and that can
come before the client's WroteRequest fires, so up to Send of the hold is
counted in Send, not Wait. The test now wants Send+Wait to cover the hold
and Wait at least half of it (the vendor's wait is still where the time
goes), and Head past Wait, as before. Test only; nettrace is unchanged.
Run (wsl-run, magpie-desktop): go test -count=30 -run
'TestCodexOwnSignInTellsWhereItsTimeWent$' ./internal/gateway ok.
Broken by hand: Wait divided by 4 in nettrace.go: red ("Wait:50.375 ...
for a 200ms hold").
Not tried: injecting the WroteRequest delay itself; the cause is read
from nettrace.go (Send = gotConn to wrote, Wait = wrote to first byte).