From 3814a09cb1850f53099cad7b71037d2a631670b9 Mon Sep 17 00:00:00 2001 From: Ignacio Hagopian Date: Wed, 17 Jan 2024 11:21:08 -0300 Subject: [PATCH] proof: test simplification Signed-off-by: Ignacio Hagopian --- proof_test.go | 10 ++++------ 1 file changed, 4 insertions(+), 6 deletions(-) diff --git a/proof_test.go b/proof_test.go index e4dd3f89..2ad1d8ed 100644 --- a/proof_test.go +++ b/proof_test.go @@ -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") @@ -790,7 +789,7 @@ 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) } @@ -798,14 +797,13 @@ func TestProofVerificationThreeStemsInSameExtensionStatus(t *testing.T) { 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) }