add more test

pull/61/head
Minh Doan 6 years ago
parent fbee5d821c
commit 33ef9a096b
  1. 3
      blockchain/merkle_tree_test.go

@ -37,12 +37,13 @@ func TestNewMerkleTree(t *testing.T) {
[]byte("node1"), []byte("node1"),
[]byte("node2"), []byte("node2"),
[]byte("node3"), []byte("node3"),
[]byte("node4"),
} }
// Level 1 // Level 1
n1 := NewMerkleNode(nil, nil, data[0]) n1 := NewMerkleNode(nil, nil, data[0])
n2 := NewMerkleNode(nil, nil, data[1]) n2 := NewMerkleNode(nil, nil, data[1])
n3 := NewMerkleNode(nil, nil, data[2]) n3 := NewMerkleNode(nil, nil, data[2])
n4 := NewMerkleNode(nil, nil, data[2]) n4 := NewMerkleNode(nil, nil, data[3])
// Level 2 // Level 2
n5 := NewMerkleNode(n1, n2, nil) n5 := NewMerkleNode(n1, n2, nil)

Loading…
Cancel
Save