Skip to content
This repository was archived by the owner on Nov 15, 2023. It is now read-only.
Merged
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
cargo fmt
  • Loading branch information
altonen committed Nov 26, 2022
commit 8c30a00cffd2c8f96b323009b22bc6235565d570
9 changes: 6 additions & 3 deletions client/network/test/src/sync.rs
Original file line number Diff line number Diff line change
Expand Up @@ -775,7 +775,9 @@ fn sync_to_tip_requires_that_sync_protocol_is_informed_about_best_block() {
let mut net = TestNet::new(1);

// Produce some blocks
let block_hash = net.peer(0).push_blocks_at_without_informing_sync(BlockId::Number(0), 3, true, true);
let block_hash =
net.peer(0)
.push_blocks_at_without_informing_sync(BlockId::Number(0), 3, true, true);

// Add a node and wait until they are connected
net.add_full_peer_with_config(Default::default());
Expand Down Expand Up @@ -820,8 +822,9 @@ fn sync_to_tip_when_we_sync_together_with_multiple_peers() {
net.peer(0)
.push_blocks_at_without_informing_sync(BlockId::Number(0), 10_000, false, false);

let block_hash2 = net.peer(1)
.push_blocks_at_without_informing_sync(BlockId::Number(0), 5_000, false, false);
let block_hash2 =
net.peer(1)
.push_blocks_at_without_informing_sync(BlockId::Number(0), 5_000, false, false);

assert!(!net.peer(2).has_block(block_hash));
net.peer(0).network_service().new_best_block_imported(block_hash, 10_000);
Expand Down