MCPcopy Create free account
hub / github.com/consensus-shipyard/ipc / assert_complete

Function assert_complete

ext/libp2p-bitswap/src/query.rs:540–547  ·  view source on GitHub ↗
(event: Option<QueryEvent>, id: QueryId, res: Result<(), Cid>)

Source from the content-addressed store, hash-verified

538 }
539
540 fn assert_complete(event: Option<QueryEvent>, id: QueryId, res: Result<(), Cid>) {
541 if let Some(QueryEvent::Complete(id2, res2)) = event {
542 assert_eq!(id, id2);
543 assert_eq!(res, res2);
544 } else {
545 panic!("{:?} is not a complete event", event);
546 }
547 }
548
549 #[test]
550 fn test_get_query_block_not_found() {

Calls

no outgoing calls