Wraps one Dispatcher adapter over a controllable fake transport. It records the message bodies
sent and the abort signals seen. Calling failNext makes the next dispatch throw a transport
error. The shared suite uses this to exercise the success, failure, and cancellation paths
uniformly across adapters.
The contract a host's harness must uphold: bodies grows by the exact string the adapter handed
the transport, one entry per dispatch; signals records the per-dispatch abort signal, with
undefined recorded when the caller passed none; failNext(error) arms only the next dispatch,
which must surface the failure as the transport error would.
Wraps one Dispatcher adapter over a controllable fake transport. It records the message bodies sent and the abort signals seen. Calling
failNextmakes the next dispatch throw a transport error. The shared suite uses this to exercise the success, failure, and cancellation paths uniformly across adapters.The contract a host's harness must uphold:
bodiesgrows by the exact string the adapter handed the transport, one entry per dispatch;signalsrecords the per-dispatch abort signal, withundefinedrecorded when the caller passed none;failNext(error)arms only the next dispatch, which must surface the failure as the transport error would.