aboutsummaryrefslogtreecommitdiffstats
path: root/rlp/encode_test.go
diff options
context:
space:
mode:
Diffstat (limited to 'rlp/encode_test.go')
-rw-r--r--rlp/encode_test.go6
1 files changed, 6 insertions, 0 deletions
diff --git a/rlp/encode_test.go b/rlp/encode_test.go
index 18b843737..0309b9258 100644
--- a/rlp/encode_test.go
+++ b/rlp/encode_test.go
@@ -40,6 +40,8 @@ func (e *encodableReader) Read(b []byte) (int, error) {
panic("called")
}
+type namedByteType byte
+
var (
_ = Encoder(&testEncoder{})
_ = Encoder(byteEncoder(0))
@@ -102,6 +104,10 @@ var encTests = []encTest{
// byte slices, strings
{val: []byte{}, output: "80"},
{val: []byte{1, 2, 3}, output: "83010203"},
+
+ {val: []namedByteType{1, 2, 3}, output: "83010203"},
+ {val: [...]namedByteType{1, 2, 3}, output: "83010203"},
+
{val: "", output: "80"},
{val: "dog", output: "83646F67"},
{