Rename ClusterInfo::new() to ClusterInfo::new_with_invalid_keypair()

This commit is contained in:
Michael Vines
2019-03-06 13:47:18 -08:00
parent 4d58bf4b28
commit bb93504965
17 changed files with 35 additions and 33 deletions

View File

@ -437,7 +437,7 @@ mod tests {
&exit,
)));
request_processor.write().unwrap().set_bank(&bank);
let cluster_info = Arc::new(RwLock::new(ClusterInfo::new(NodeInfo::default())));
let cluster_info = Arc::new(RwLock::new(ClusterInfo::new_with_invalid_keypair(NodeInfo::default())));
let leader = NodeInfo::new_with_socketaddr(&socketaddr!("127.0.0.1:1234"));
cluster_info.write().unwrap().insert_info(leader.clone());
@ -638,7 +638,7 @@ mod tests {
request_processor.set_bank(&bank);
Arc::new(RwLock::new(request_processor))
},
cluster_info: Arc::new(RwLock::new(ClusterInfo::new(NodeInfo::default()))),
cluster_info: Arc::new(RwLock::new(ClusterInfo::new_with_invalid_keypair(NodeInfo::default()))),
};
let req =
@ -655,7 +655,7 @@ mod tests {
#[test]
fn test_rpc_get_leader_addr() {
let cluster_info = Arc::new(RwLock::new(ClusterInfo::new(NodeInfo::default())));
let cluster_info = Arc::new(RwLock::new(ClusterInfo::new_with_invalid_keypair(NodeInfo::default())));
assert_eq!(
get_leader_addr(&cluster_info),
Err(Error {