Delete unused create_test_recent_blockhashes
This commit is contained in:
parent
a94920a4ea
commit
a69ee79111
|
@ -2,10 +2,7 @@
|
|||
#![allow(clippy::integer_arithmetic)]
|
||||
use {
|
||||
crate::{
|
||||
declare_deprecated_sysvar_id,
|
||||
fee_calculator::FeeCalculator,
|
||||
hash::{hash, Hash},
|
||||
sysvar::Sysvar,
|
||||
declare_deprecated_sysvar_id, fee_calculator::FeeCalculator, hash::Hash, sysvar::Sysvar,
|
||||
},
|
||||
std::{cmp::Ordering, collections::BinaryHeap, iter::FromIterator, ops::Deref},
|
||||
};
|
||||
|
@ -145,22 +142,6 @@ impl Deref for RecentBlockhashes {
|
|||
}
|
||||
}
|
||||
|
||||
pub fn create_test_recent_blockhashes(start: usize) -> RecentBlockhashes {
|
||||
let blocks: Vec<_> = (start..start + MAX_ENTRIES)
|
||||
.map(|i| {
|
||||
(
|
||||
i as u64,
|
||||
hash(&bincode::serialize(&i).unwrap()),
|
||||
i as u64 * 100,
|
||||
)
|
||||
})
|
||||
.collect();
|
||||
blocks
|
||||
.iter()
|
||||
.map(|(i, hash, lamports_per_signature)| IterItem(*i, hash, *lamports_per_signature))
|
||||
.collect()
|
||||
}
|
||||
|
||||
#[cfg(test)]
|
||||
mod tests {
|
||||
use {super::*, crate::clock::MAX_PROCESSING_AGE};
|
||||
|
|
Loading…
Reference in New Issue