The async mock stream framework offers a stream that pauses itself to allow the tester to inspect state that has been written to it or read from it by the network interface. Those "pauses" are implemented as follows:
This causes the NIA's thread, which has called write(), to hang until the test unblocks it. Then it cannot use that thread for other things, like checking for timed out operations, while the write is "blocked on a socket."
We should return instead of blocking there, essentially pausing that path of the state machine. The call to unblock(), instead of actually unblocking, should post a new handler to the io_service that runs the part of write() that would have happened after the block.