MCPcopy Create free account
hub / github.com/NodeDB-Lab/nodedb / queue_full_increments_dropped

Function queue_full_increments_dropped

nodedb/src/control/notify_bus.rs:306–314  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

304
305 #[tokio::test]
306 async fn queue_full_increments_dropped() {
307 let bus = NotifyBus::new(2); // tiny cap
308 let t = tenant(1);
309 let (_, _rx) = bus.listen(t, "ch"); // don't drain
310 bus.notify(t, "ch", "a");
311 bus.notify(t, "ch", "b"); // fills the queue
312 bus.notify(t, "ch", "c"); // should drop
313 assert_eq!(bus.total_dropped(), 1);
314 }
315
316 #[tokio::test]
317 async fn unlisten_all() {

Callers

nothing calls this directly

Calls 3

tenantFunction · 0.70
listenMethod · 0.45
notifyMethod · 0.45

Tested by

no test coverage detected