Skip to content

Commit

Permalink
add snapshot for block
Browse files Browse the repository at this point in the history
  • Loading branch information
harrysolovay committed Oct 2, 2024
1 parent ef50cad commit b6c4d2a
Show file tree
Hide file tree
Showing 2 changed files with 2,579 additions and 1 deletion.
3 changes: 2 additions & 1 deletion tests/block.rs
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@ use std::sync::OnceLock;

use anyhow::Result;
use futures::{stream::FuturesUnordered, StreamExt};
use insta::assert_debug_snapshot;
use mina_mesh::{
BlockRequest, BlockResponse, MinaMeshConfig, MinaMeshError, NetworkIdentifier, PartialBlockIdentifier,
};
Expand All @@ -20,6 +21,7 @@ async fn specified() -> Result<()> {
}
maybe_prev = Some(resolved);
}
assert_debug_snapshot!(maybe_prev);
Ok(())
}

Expand Down Expand Up @@ -49,7 +51,6 @@ fn network_identifier() -> &'static NetworkIdentifier {
async fn unspecified() -> Result<()> {
let mina_mesh = MinaMeshConfig::default().to_mina_mesh().await?;
let result = mina_mesh.block(BlockRequest::new(network_identifier().to_owned(), PartialBlockIdentifier::new())).await;
println!("HELLO: {:?}", result);
assert!(result.is_ok());
Ok(())
}
Loading

0 comments on commit b6c4d2a

Please sign in to comment.