Expand description
In-memory connections a test can play the server on, and a made-up protocol that stamps
everything it encodes so a test can tell which protocol the client settled on. Behind the
test-support feature, for this crate’s own tests and for the tests of anything built on
it.
Everything here panics rather than returning an error: a test that can’t have what it asked for has nothing left to assert.
Structs§
- Fake
Conn - The server’s end of one connection. Like Rails it keeps the identifiers it has confirmed and ignores a second subscribe for one of them, so a test reads off the wire exactly what a Rails server would act on, in the order the test acts on it.
- Fake
Protocol - Speaks a made-up subprotocol and stamps everything it encodes, so a test can tell which protocol the client settled on.
- Fake
Transport - A transport whose connections a test accepts and plays the server on.
- Sent
Command - A command as the client wrote it.
Constants§
- WAIT
- How long a test will hang around for something that should already have happened.
Functions§
- quote
valueas a JSON string literal, for building frames by hand.