Zebra/zebra-network/src/peer/connection
teor c76ff56cd1
fix(network): Add a send timeout to outbound peer messages (#3417)
* fix(network): add a send timeout to outbound peer messages

* test(network): test peer send and receive timeouts

And the equivalent success cases:
- spawn the run loop with no messages
- spawn the run loop and send and receive a message

* test(network): check for specific error types in the tests

And add an outbound error test that doesn't expect a response.

* test(network): use bounded fake peer connection channels

This lets us actually trigger send timeouts in the tests.

* refactor(network): rename some confusing types and variables

fastmod peer_inbound_tx peer_tx zebra*
fastmod peer_inbound_rx peer_rx zebra*

fastmod ClientSendTimeout ConnectionSendTimeout zebra*
fastmod ClientReceiveTimeout ConnectionReceiveTimeout zebra*

* doc(network test): explain the purpose of each peer connection test vector
2022-01-31 15:22:00 -03:00
..
tests fix(network): Add a send timeout to outbound peer messages (#3417) 2022-01-31 15:22:00 -03:00
peer_tx.rs fix(network): Add a send timeout to outbound peer messages (#3417) 2022-01-31 15:22:00 -03:00
tests.rs fix(network): Add a send timeout to outbound peer messages (#3417) 2022-01-31 15:22:00 -03:00