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

Function send_ok

nodedb-test-support/src/tx_batch_helpers.rs:61–80  ·  view source on GitHub ↗
(
    core: &mut CoreLoop,
    tx: &mut Producer<BridgeRequest>,
    rx: &mut Consumer<BridgeResponse>,
    plan: PhysicalPlan,
)

Source from the content-addressed store, hash-verified

59}
60
61pub fn send_ok(
62 core: &mut CoreLoop,
63 tx: &mut Producer<BridgeRequest>,
64 rx: &mut Consumer<BridgeResponse>,
65 plan: PhysicalPlan,
66) -> Vec<u8> {
67 tx.try_push(BridgeRequest {
68 inner: make_request(plan),
69 })
70 .unwrap();
71 core.tick();
72 let resp = rx.try_pop().unwrap();
73 assert_eq!(
74 resp.inner.status,
75 Status::Ok,
76 "send_ok expected Ok, got {:?}",
77 resp.inner.error_code
78 );
79 resp.inner.payload.to_vec()
80}
81
82pub fn send_raw(
83 core: &mut CoreLoop,

Callers 1

assert_columnar_countFunction · 0.70

Calls 5

try_pushMethod · 0.80
try_popMethod · 0.80
make_requestFunction · 0.70
tickMethod · 0.45
to_vecMethod · 0.45

Tested by

no test coverage detected