Fix the failing networking tests (#2904)

This commit is contained in:
Pierre Krieger authored and DemiMarie-parity committed 2019-06-18 21:03:38 -04:00
1 parent 925a90f57f
commit de6d541c74
1 file changed
+9 -5
@@ -58,11 +58,15 @@ fn build_nodes<T: CustomMessage + Send + 'static>()
let (peerset, _) = peerset::Peerset::from_config(peerset::PeersetConfig {
in_peers: 25,
out_peers: 25,
bootnodes: keypairs
.iter()
.enumerate()
.filter_map(|(n, p)| if n != index { Some(p.public().into_peer_id()) } else { None })
.collect(),
bootnodes: if index == 0 {
keypairs
.iter()
.skip(1)
.map(|keypair| keypair.public().into_peer_id())
.collect()
} else {
vec![]
},
reserved_only: false,
reserved_nodes: Vec::new(),
});