pub async fn mock_component<S, Event>(
sender: Sender<Event>,
handles: LocalComponentHandles,
) -> Result<(), Error>where
S: DiscoverableProtocolMarker,
Event: From<<<S as ProtocolMarker>::RequestStream as TryStream>::Ok> + Send + 'static,
<<S as ProtocolMarker>::RequestStream as TryStream>::Ok: Debug,Expand description
A mock component that provides the generic service S. The request stream
of the service is processed and any requests relayed to the provided sender.