Skip to content

Commit 9472474

Browse files
committed
test []byte behavior
1 parent ad83167 commit 9472474

File tree

1 file changed

+8
-0
lines changed

1 file changed

+8
-0
lines changed

value_tests/slice_test.go

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -6,12 +6,20 @@ func init() {
66
[]interface{}{"hello"},
77
nilSlice,
88
&nilSlice,
9+
selectedMarshalCase{[]byte{1,2,3}},
910
)
1011
unmarshalCases = append(unmarshalCases, unmarshalCase{
1112
ptr: (*[]string)(nil),
1213
input: "null",
1314
}, unmarshalCase{
1415
ptr: (*[]string)(nil),
1516
input: "[]",
17+
}, unmarshalCase{
18+
ptr: (*[]byte)(nil),
19+
input: "[1,2,3]",
20+
}, unmarshalCase{
21+
ptr: (*[]byte)(nil),
22+
input: `"aGVsbG8="`,
23+
selected: true,
1624
})
1725
}

0 commit comments

Comments
 (0)