Commit 7abc7289 authored by Juan Batiz-Benet's avatar Juan Batiz-Benet

u.Hash - error

the u.Hash error can be safely ignored (panic) because multihash
only fails from the selection of hash function. If the fn + length
are valid, it won't error.

cc @whyrusleeping
parent 413d09dc
......@@ -23,12 +23,7 @@ func TestBlocks(t *testing.T) {
return
}
h, err := u.Hash([]byte("beep boop"))
if err != nil {
t.Error("failed to hash data", err)
return
}
h := u.Hash([]byte("beep boop"))
if !bytes.Equal(b.Multihash, h) {
t.Error("Block Multihash and data multihash not equal")
}
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment