diff options
author | obscuren <geffobscura@gmail.com> | 2015-03-19 17:57:02 +0800 |
---|---|---|
committer | obscuren <geffobscura@gmail.com> | 2015-03-19 17:57:02 +0800 |
commit | d7ab716eea1d1892e3358b1dece6b0e2cd31fce8 (patch) | |
tree | c0fe4ca2dc47ff8512065f3601b9f3ab6b21dd43 /trie/trie_test.go | |
parent | e67d32b46744928b07b4d964ae3dede9a1ffdddf (diff) | |
download | go-tangerine-d7ab716eea1d1892e3358b1dece6b0e2cd31fce8.tar.gz go-tangerine-d7ab716eea1d1892e3358b1dece6b0e2cd31fce8.tar.zst go-tangerine-d7ab716eea1d1892e3358b1dece6b0e2cd31fce8.zip |
Fixed mkdnode & added some tests
Diffstat (limited to 'trie/trie_test.go')
-rw-r--r-- | trie/trie_test.go | 11 |
1 files changed, 10 insertions, 1 deletions
diff --git a/trie/trie_test.go b/trie/trie_test.go index 1393e0c97..16311aadf 100644 --- a/trie/trie_test.go +++ b/trie/trie_test.go @@ -5,8 +5,8 @@ import ( "fmt" "testing" - "github.com/ethereum/go-ethereum/crypto" "github.com/ethereum/go-ethereum/common" + "github.com/ethereum/go-ethereum/crypto" ) type Db map[string][]byte @@ -32,6 +32,15 @@ func TestEmptyTrie(t *testing.T) { } } +func TestNull(t *testing.T) { + trie := NewEmpty() + + key := make([]byte, 32) + value := common.FromHex("0x823140710bf13990e4500136726d8b55") + trie.Update(key, value) + value = trie.Get(key) +} + func TestInsert(t *testing.T) { trie := NewEmpty() |