Skip to content

Commit

Permalink
proof: test simplification
Browse files Browse the repository at this point in the history
Signed-off-by: Ignacio Hagopian <[email protected]>
  • Loading branch information
jsign committed Jan 17, 2024
1 parent 0a3b83a commit 3814a09
Showing 1 changed file with 4 additions and 6 deletions.
10 changes: 4 additions & 6 deletions proof_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -780,7 +780,6 @@ func TestStatelessDeserializeDepth2(t *testing.T) {
func TestProofVerificationThreeStemsInSameExtensionStatus(t *testing.T) {
t.Parallel()

key1_0, _ := hex.DecodeString("0000000000000000000000000000000000000000000000000000000000000000")
key2_0, _ := hex.DecodeString("0002000000000000000000000000000000000000000000000000000000000000")
key3_0, _ := hex.DecodeString("0003000000000000000000000000000000000000000000000000000000000000")
key3_1, _ := hex.DecodeString("0003000000000000000000000000000000000000000000000000000000000001")
Expand All @@ -790,22 +789,21 @@ func TestProofVerificationThreeStemsInSameExtensionStatus(t *testing.T) {
string(key3_0): fourtyKeyTest,
string(key3_1): fourtyKeyTest,
}
proveKeys := keylist{key1_0, key2_0, key3_0, key3_1, key4_0}
proveKeys := keylist{zeroKeyTest, key2_0, key3_0, key3_1, key4_0}

testSerializeDeserializeProof(t, insertKVs, proveKeys)
}

func TestProofVerificationTwoLeavesWithDifferentValues(t *testing.T) {
t.Parallel()

key1, _ := hex.DecodeString("0000000000000000000000000000000000000000000000000000000000000000")
key2, _ := hex.DecodeString("0100000000000000000000000000000000000000000000000000000000000000")

insertKVs := map[string][]byte{
string(key1): fourtyKeyTest,
string(key2): forkOneKeyTest,
string(zeroKeyTest): fourtyKeyTest,
string(key2): forkOneKeyTest,
}
proveKeys := keylist{key1, key2}
proveKeys := keylist{zeroKeyTest, key2}

testSerializeDeserializeProof(t, insertKVs, proveKeys)
}
Expand Down

0 comments on commit 3814a09

Please sign in to comment.