aboutsummaryrefslogtreecommitdiffstats
path: root/ethutil
diff options
context:
space:
mode:
authorobscuren <geffobscura@gmail.com>2014-02-15 19:41:17 +0800
committerobscuren <geffobscura@gmail.com>2014-02-15 19:41:17 +0800
commit5883446b219a2980d67ff604c7f227089e5c8619 (patch)
tree49bc045d944fed198f20efc8f85d2da8913fbd03 /ethutil
parent9bcb3d22168f5f02cd32ff23df60239156ddc899 (diff)
downloaddexon-5883446b219a2980d67ff604c7f227089e5c8619.tar
dexon-5883446b219a2980d67ff604c7f227089e5c8619.tar.gz
dexon-5883446b219a2980d67ff604c7f227089e5c8619.tar.bz2
dexon-5883446b219a2980d67ff604c7f227089e5c8619.tar.lz
dexon-5883446b219a2980d67ff604c7f227089e5c8619.tar.xz
dexon-5883446b219a2980d67ff604c7f227089e5c8619.tar.zst
dexon-5883446b219a2980d67ff604c7f227089e5c8619.zip
Fixed test
Diffstat (limited to 'ethutil')
-rw-r--r--ethutil/rlp_test.go10
1 files changed, 2 insertions, 8 deletions
diff --git a/ethutil/rlp_test.go b/ethutil/rlp_test.go
index 2bddeec8f..54f929ebd 100644
--- a/ethutil/rlp_test.go
+++ b/ethutil/rlp_test.go
@@ -2,8 +2,6 @@ package ethutil
import (
"bytes"
- "encoding/hex"
- "fmt"
"math/big"
"reflect"
"testing"
@@ -63,7 +61,7 @@ func TestEncode(t *testing.T) {
str := string(bytes)
if str != strRes {
- t.Error(fmt.Sprintf("Expected %q, got %q", strRes, str))
+ t.Errorf("Expected %q, got %q", strRes, str)
}
sliceRes := "\xcc\x83dog\x83god\x83cat"
@@ -71,7 +69,7 @@ func TestEncode(t *testing.T) {
bytes = Encode(strs)
slice := string(bytes)
if slice != sliceRes {
- t.Error(fmt.Sprintf("Expected %q, got %q", sliceRes, slice))
+ t.Error("Expected %q, got %q", sliceRes, slice)
}
intRes := "\x82\x04\x00"
@@ -108,13 +106,9 @@ func TestEncodeDecodeBigInt(t *testing.T) {
encoded := Encode(bigInt)
value := NewValueFromBytes(encoded)
- fmt.Println(value.BigInt(), bigInt)
if value.BigInt().Cmp(bigInt) != 0 {
t.Errorf("Expected %v, got %v", bigInt, value.BigInt())
}
-
- dec, _ := hex.DecodeString("52f4fc1e")
- fmt.Println(NewValueFromBytes(dec).BigInt())
}
func TestEncodeDecodeBytes(t *testing.T) {