diff options
author | obscuren <geffobscura@gmail.com> | 2014-01-16 06:32:30 +0800 |
---|---|---|
committer | obscuren <geffobscura@gmail.com> | 2014-01-16 06:32:30 +0800 |
commit | 4ea93eba501cf996395e4c0829e21cab77267cf9 (patch) | |
tree | c33e0b3294ac3338426c818ecf35dcbae69e38e0 | |
parent | 44900e363cbc81b640bc16bcc7e6a50c22352be4 (diff) | |
download | go-tangerine-4ea93eba501cf996395e4c0829e21cab77267cf9.tar.gz go-tangerine-4ea93eba501cf996395e4c0829e21cab77267cf9.tar.zst go-tangerine-4ea93eba501cf996395e4c0829e21cab77267cf9.zip |
Updated tests
-rw-r--r-- | dagger_test.go | 3 | ||||
-rw-r--r-- | test_runner_test.go | 8 |
2 files changed, 7 insertions, 4 deletions
diff --git a/dagger_test.go b/dagger_test.go index 58cdd6afd..616577a39 100644 --- a/dagger_test.go +++ b/dagger_test.go @@ -1,13 +1,14 @@ package main import ( + "github.com/ethereum/ethutil-go" "math/big" "testing" ) func BenchmarkDaggerSearch(b *testing.B) { hash := big.NewInt(0) - diff := BigPow(2, 36) + diff := ethutil.BigPow(2, 36) o := big.NewInt(0) // nonce doesn't matter. We're only testing against speed, not validity // Reset timer so the big generation isn't included in the benchmark diff --git a/test_runner_test.go b/test_runner_test.go index 5abe20002..5abf0c8df 100644 --- a/test_runner_test.go +++ b/test_runner_test.go @@ -3,6 +3,8 @@ package main import ( "encoding/hex" _ "fmt" + "github.com/ethereum/ethdb-go" + "github.com/ethereum/ethutil-go" "testing" ) @@ -15,8 +17,8 @@ var testsource = `{"Inputs":{ }` func TestTestRunner(t *testing.T) { - db, _ := NewMemDatabase() - trie := NewTrie(db, "") + db, _ := ethdb.NewMemDatabase() + trie := ethutil.NewTrie(db, "") runner := NewTestRunner(t) runner.RunFromString(testsource, func(source *TestSource) { @@ -24,7 +26,7 @@ func TestTestRunner(t *testing.T) { trie.Update(key, value) } - if hex.EncodeToString([]byte(trie.root)) != source.Expectation { + if hex.EncodeToString([]byte(trie.Root)) != source.Expectation { t.Error("trie root did not match") } }) |