Skip to content

Commit

Permalink
rebase fixes
Browse files Browse the repository at this point in the history
Signed-off-by: Ignacio Hagopian <[email protected]>
  • Loading branch information
jsign committed Oct 4, 2023
1 parent a50c940 commit 583997c
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions proof_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -950,7 +950,7 @@ func TestProofDeduping(t *testing.T) {
root.Insert(key1, fourtyKeyTest, nil)
root.Insert(key2, fourtyKeyTest, nil)

proof, _, _, _, _ := MakeVerkleMultiProof(root, keylist{key1, key2})
proof, _, _, _, _ := MakeVerkleMultiProof(root, nil, keylist{key1, key2}, nil)

serialized, statediff, err := SerializeProof(proof)
if err != nil {
Expand All @@ -962,16 +962,16 @@ func TestProofDeduping(t *testing.T) {
t.Fatalf("error deserializing proof: %v", err)
}

droot, err := TreeFromProof(dproof, root.Commit())
droot, err := PreStateTreeFromProof(dproof, root.Commit())
if err != nil {
t.Fatal(err)
}

if !Equal(droot.Commit(), root.Commit()) {
if !droot.Commit().Equal(root.Commit()) {
t.Fatal("differing root commitments")
}

if !Equal(droot.(*InternalNode).children[0].Commit(), root.(*InternalNode).children[0].Commit()) {
if !droot.(*InternalNode).children[0].Commit().Equal(root.(*InternalNode).children[0].Commit()) {
t.Fatal("differing commitment for child #0")
}
}

0 comments on commit 583997c

Please sign in to comment.