aboutsummaryrefslogtreecommitdiffstats
path: root/common/hexutil/hexutil_test.go
diff options
context:
space:
mode:
Diffstat (limited to 'common/hexutil/hexutil_test.go')
-rw-r--r--common/hexutil/hexutil_test.go8
1 files changed, 8 insertions, 0 deletions
diff --git a/common/hexutil/hexutil_test.go b/common/hexutil/hexutil_test.go
index 324e9d348..68d8a40e0 100644
--- a/common/hexutil/hexutil_test.go
+++ b/common/hexutil/hexutil_test.go
@@ -83,6 +83,10 @@ var (
{input: `0x01`, wantErr: ErrLeadingZero},
{input: `0xx`, wantErr: ErrSyntax},
{input: `0x1zz01`, wantErr: ErrSyntax},
+ {
+ input: `0x10000000000000000000000000000000000000000000000000000000000000000`,
+ wantErr: ErrBig256Range,
+ },
// valid
{input: `0x0`, want: big.NewInt(0)},
{input: `0x2`, want: big.NewInt(0x2)},
@@ -99,6 +103,10 @@ var (
input: `0xffffffffffffffffffffffffffffffffffff`,
want: referenceBig("ffffffffffffffffffffffffffffffffffff"),
},
+ {
+ input: `0xffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff`,
+ want: referenceBig("ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff"),
+ },
}
decodeUint64Tests = []unmarshalTest{