chore(trie): make MultiProofTargets a type alias (#13364)

This commit is contained in:
Alexey Shekhirin
2024-12-13 09:02:39 +00:00
committed by GitHub
parent 02f76b813e
commit 008cb25d00
6 changed files with 40 additions and 47 deletions

View File

@ -39,9 +39,7 @@ fn includes_empty_node_preimage() {
let state_root = StateRoot::from_tx(provider.tx_ref()).root().unwrap();
let multiproof = Proof::from_tx(provider.tx_ref())
.multiproof(
HashMap::from_iter([(hashed_address, HashSet::from_iter([hashed_slot]))]).into(),
)
.multiproof(HashMap::from_iter([(hashed_address, HashSet::from_iter([hashed_slot]))]))
.unwrap();
let witness = TrieWitness::from_tx(provider.tx_ref())
@ -79,9 +77,7 @@ fn includes_nodes_for_destroyed_storage_nodes() {
let state_root = StateRoot::from_tx(provider.tx_ref()).root().unwrap();
let multiproof = Proof::from_tx(provider.tx_ref())
.multiproof(
HashMap::from_iter([(hashed_address, HashSet::from_iter([hashed_slot]))]).into(),
)
.multiproof(HashMap::from_iter([(hashed_address, HashSet::from_iter([hashed_slot]))]))
.unwrap();
let witness =
@ -126,13 +122,10 @@ fn correctly_decodes_branch_node_values() {
let state_root = StateRoot::from_tx(provider.tx_ref()).root().unwrap();
let multiproof = Proof::from_tx(provider.tx_ref())
.multiproof(
HashMap::from_iter([(
hashed_address,
HashSet::from_iter([hashed_slot1, hashed_slot2]),
)])
.into(),
)
.multiproof(HashMap::from_iter([(
hashed_address,
HashSet::from_iter([hashed_slot1, hashed_slot2]),
)]))
.unwrap();
let witness = TrieWitness::from_tx(provider.tx_ref())