Skip to content

Commit 0ea75ee

Browse files
committed
msgpack: add string decode test for Nil
1 parent 96d7cca commit 0ea75ee

File tree

1 file changed

+10
-0
lines changed

1 file changed

+10
-0
lines changed

msgpack/decode_test.go

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -964,6 +964,16 @@ func Test_stringDecoder(t *testing.T) {
964964
want string
965965
wantErr bool
966966
}{
967+
"Nil": {
968+
ds: &decodeState{
969+
Decoder: &Decoder{
970+
p: nil,
971+
t: Nil,
972+
},
973+
},
974+
want: string(""),
975+
wantErr: false,
976+
},
967977
"Binary": {
968978
ds: &decodeState{
969979
Decoder: &Decoder{

0 commit comments

Comments
 (0)