Files
multica/server
Bohan-J 9738b80e90 test(channel): wait for the async media goroutine before asserting on it
TestRouter_Ingested_InTxMark_FinalizeNone read two pieces of state produced
by the media goroutine (r.mediaWg) without waiting for it: the resolve count,
and the binding that only happens after resolve returns. Router.Handle does
not wait for either, so on a loaded CI runner the assertions ran first and the
test failed with "ingested message resolved media 0 times, want 1".

Observed on a PR whose diff did not touch this package, and confirmed by
re-running the identical commit green with no code change.

Both assertions now use waitFor, matching what the sibling media assertions in
this file already do — TestRouter_AppendErrorReleasesClaimAndAllowsMediaRetry
wraps the same counter. The assertions themselves are unchanged.

Co-authored-by: multica-agent <github@multica.ai>
2026-07-29 16:11:18 +08:00
..