Expand description
In-process Redis test transport used by application unit tests and the conformance suite.
Gated by the testing cargo feature. The broker is a synchronous dispatcher: publish fans the
message out to every subscriber whose stream key matches exactly. Public surface:
RedisTestBroker- a fullBroker+Subscribe+DescribeServerbacked by an in-process key router, which also implementsruststream::testing::TestableBrokerso it plugs straight into theTestAppharness andconformance::harness::run_suite;RedisTestPublisher-Publisher;RedisTestSubscriber/RedisTestMessage-SubscriberandIncomingMessageimpls withnack(requeue = true)redelivery (re-sent into the same subscriber’s queue).
No redis-server, no docker, no network. Broker-specific edge cases (consumer-group cursors,
XAUTOCLAIM redelivery, idle reclaim, MAXLEN trimming, dead-letter routing) are out of scope
here. Exercise them against a real Redis server.
Structs§
- Redis
Test Broker - In-process Redis broker used for handler-level tests.
- Redis
Test Message - Message handed to handlers from a
RedisTestSubscriber. - Redis
Test Publisher - Publisher returned by
crate::testing::RedisTestBroker::publisher. - Redis
Test Subscriber - Subscriber returned by
crate::testing::RedisTestBroker::subscribe.