Skip to content

Commit

Permalink
Add an extra test for single parsing
Browse files Browse the repository at this point in the history
  • Loading branch information
dominickpastore committed Jun 1, 2020
1 parent 5d1d04e commit b494feb
Showing 1 changed file with 7 additions and 0 deletions.
7 changes: 7 additions & 0 deletions test/tests.c
Original file line number Diff line number Diff line change
Expand Up @@ -522,6 +522,13 @@ int test_multiple_objects(void) {
JSMN_PRIMITIVE, "27"));
#endif

js = " ";
#ifdef JSMN_SINGLE
check(parse(js, JSMN_ERROR_PART, 1));
#else
check(parse(js, 0, 0));
#endif

#ifdef JSMN_SINGLE
#ifdef JSMN_PERMISSIVE_PRIMITIVES
js = "tru{\"def\": 123}";
Expand Down

0 comments on commit b494feb

Please sign in to comment.