Add yajl test for trailing commas in arrays and maps

This commit is contained in:
Andrew Johnson
2017-06-26 23:34:07 -05:00
parent 50028f2eda
commit 7a571989f8
+23
View File
@@ -3000,6 +3000,29 @@ sub cases {
"memory leaks:\t0"
]
},
{
name => "trailing_commas",
opts => [],
input => [
"{\"array\":[1,2,],\"map\":{\"a\":1,},}",
""
],
gives => [
"map open '{'",
"key: 'array'",
"array open '['",
"integer: 1",
"integer: 2",
"array close ']'",
"key: 'map'",
"map open '{'",
"key: 'a'",
"integer: 1",
"map close '}'",
"map close '}'",
"memory leaks:\t0"
]
},
{
name => "true",
opts => [],