Settings
Help

Module net

Module net 

Source
Expand description

Implements a simple mock network for testing purposes.

StructsΒ§

ListenerEntry πŸ”’
The MockNetwork’s view of a listener.
MockNetListener
A [NetStreamListener] implementation returned by a MockNetProvider.
MockNetProvider
A view of a single host’s access to a MockNetwork.
MockNetProviderInner πŸ”’
Shared part of a MockNetworkProvider.
MockNetwork
A simulated Internet, for testing.
MockTlsConnector
Mock TLS connector for use with MockNetProvider.
MockTlsStream
Mock TLS connector for use with MockNetProvider.
MockUdpSocket
A very poor imitation of a UDP socket
ProviderBuilder
A builder object used to configure a MockNetProvider

EnumsΒ§

AddrBehavior πŸ”’
A possible non-error behavior from an address
MockNetError
Inner error type returned when a MockNetwork operation fails.

FunctionsΒ§

err πŸ”’
Wrap k in a new std::io::Error.

Type AliasesΒ§

ConnReceiver πŸ”’
A channel receiver that listeners use to receive incoming connections.
ConnSender πŸ”’
A channel sender that we use to send incoming connections to listeners.