diff options
author | Felix Lange <fjl@twurst.com> | 2016-04-15 19:45:15 +0800 |
---|---|---|
committer | Felix Lange <fjl@twurst.com> | 2016-04-15 19:45:15 +0800 |
commit | 6197fbf8d70c1aa96c3e87de91ff3f46f454c1ea (patch) | |
tree | 1b3b3677892e2d94400f3604dc6c2dda4c05ccd4 /core/database_util_test.go | |
parent | 5c17b2f5211ec98a87140c874483681de4e34391 (diff) | |
parent | bf5ae502ef179490a039c9bcd66d32cd5a7ce5e9 (diff) | |
download | dexon-6197fbf8d70c1aa96c3e87de91ff3f46f454c1ea.tar dexon-6197fbf8d70c1aa96c3e87de91ff3f46f454c1ea.tar.gz dexon-6197fbf8d70c1aa96c3e87de91ff3f46f454c1ea.tar.bz2 dexon-6197fbf8d70c1aa96c3e87de91ff3f46f454c1ea.tar.lz dexon-6197fbf8d70c1aa96c3e87de91ff3f46f454c1ea.tar.xz dexon-6197fbf8d70c1aa96c3e87de91ff3f46f454c1ea.tar.zst dexon-6197fbf8d70c1aa96c3e87de91ff3f46f454c1ea.zip |
Merge pull request #2458 from fjl/go-vet
all: fix go vet warnings
Diffstat (limited to 'core/database_util_test.go')
-rw-r--r-- | core/database_util_test.go | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/core/database_util_test.go b/core/database_util_test.go index ce1ffea8a..9ef787624 100644 --- a/core/database_util_test.go +++ b/core/database_util_test.go @@ -196,7 +196,7 @@ func TestBlockStorage(t *testing.T) { if entry := GetBody(db, block.Hash()); entry == nil { t.Fatalf("Stored body not found") } else if types.DeriveSha(types.Transactions(entry.Transactions)) != types.DeriveSha(block.Transactions()) || types.CalcUncleHash(entry.Uncles) != types.CalcUncleHash(block.Uncles()) { - t.Fatalf("Retrieved body mismatch: have %v, want %v", entry, &types.Body{block.Transactions(), block.Uncles()}) + t.Fatalf("Retrieved body mismatch: have %v, want %v", entry, block.Body()) } // Delete the block and verify the execution DeleteBlock(db, block.Hash()) @@ -230,7 +230,7 @@ func TestPartialBlockStorage(t *testing.T) { DeleteHeader(db, block.Hash()) // Store a body and check that it's not recognized as a block - if err := WriteBody(db, block.Hash(), &types.Body{block.Transactions(), block.Uncles()}); err != nil { + if err := WriteBody(db, block.Hash(), block.Body()); err != nil { t.Fatalf("Failed to write body into database: %v", err) } if entry := GetBlock(db, block.Hash()); entry != nil { @@ -242,7 +242,7 @@ func TestPartialBlockStorage(t *testing.T) { if err := WriteHeader(db, block.Header()); err != nil { t.Fatalf("Failed to write header into database: %v", err) } - if err := WriteBody(db, block.Hash(), &types.Body{block.Transactions(), block.Uncles()}); err != nil { + if err := WriteBody(db, block.Hash(), block.Body()); err != nil { t.Fatalf("Failed to write body into database: %v", err) } if entry := GetBlock(db, block.Hash()); entry == nil { |