Reduced num_nodes in full_mesh gossipsub test (#718)

This commit is contained in:
Pawan Dhananjay 2019-12-12 17:08:38 +05:30 committed by Age Manning
parent ba1cbbba55
commit b9d00ee8b8

View File

@ -83,7 +83,11 @@ fn test_gossipsub_full_mesh_publish() {
// set up the logging. The level and enabled or not // set up the logging. The level and enabled or not
let log = common::build_log(Level::Info, false); let log = common::build_log(Level::Info, false);
let num_nodes = 20; // Note: This test does not propagate gossipsub messages.
// Having `num_nodes` > `mesh_n_high` may give inconsistent results
// as nodes may get pruned out of the mesh before the gossipsub message
// is published to them.
let num_nodes = 12;
let mut nodes = common::build_full_mesh(log, num_nodes, Some(11320)); let mut nodes = common::build_full_mesh(log, num_nodes, Some(11320));
let mut publishing_node = nodes.pop().unwrap(); let mut publishing_node = nodes.pop().unwrap();
let pubsub_message = PubsubMessage::Block(vec![0; 4]); let pubsub_message = PubsubMessage::Block(vec![0; 4]);