diff options
author | Lloyd Hilaiel <lloyd@hilaiel.com> | 2009-04-24 15:01:24 -0600 |
---|---|---|
committer | Lloyd Hilaiel <lloyd@hilaiel.com> | 2009-04-24 15:01:50 -0600 |
commit | 6cd37cb7b55e0561979ba1471089403a498feb1a (patch) | |
tree | f8daaaf737cef5f52c29235631f23cf11b4ecc90 /test | |
parent | 76e51a43d06e20b36433147e5fa2379d5c140399 (diff) | |
download | yajl-6cd37cb7b55e0561979ba1471089403a498feb1a.tar.gz |
fix bug in UTF8 validation, add unit tests for 3 and 4 byte utf8 strings
Diffstat (limited to 'test')
-rw-r--r-- | test/cases/four_byte_utf8.json | 2 | ||||
-rw-r--r-- | test/cases/four_byte_utf8.json.gold | 5 | ||||
-rw-r--r-- | test/cases/three_byte_utf8.json | 1 | ||||
-rw-r--r-- | test/cases/three_byte_utf8.json.gold | 7 |
4 files changed, 15 insertions, 0 deletions
diff --git a/test/cases/four_byte_utf8.json b/test/cases/four_byte_utf8.json new file mode 100644 index 0000000..582c575 --- /dev/null +++ b/test/cases/four_byte_utf8.json @@ -0,0 +1,2 @@ +{ "U+10ABCD": "" } + diff --git a/test/cases/four_byte_utf8.json.gold b/test/cases/four_byte_utf8.json.gold new file mode 100644 index 0000000..f6260f2 --- /dev/null +++ b/test/cases/four_byte_utf8.json.gold @@ -0,0 +1,5 @@ +map open '{' +key: 'U+10ABCD' +string: '' +map close '}' +memory leaks: 0 diff --git a/test/cases/three_byte_utf8.json b/test/cases/three_byte_utf8.json new file mode 100644 index 0000000..9c9e656 --- /dev/null +++ b/test/cases/three_byte_utf8.json @@ -0,0 +1 @@ +{"matzue": "松江", "asakusa": "浅草"} diff --git a/test/cases/three_byte_utf8.json.gold b/test/cases/three_byte_utf8.json.gold new file mode 100644 index 0000000..7d95fae --- /dev/null +++ b/test/cases/three_byte_utf8.json.gold @@ -0,0 +1,7 @@ +map open '{' +key: 'matzue' +string: '松江' +key: 'asakusa' +string: '浅草' +map close '}' +memory leaks: 0 |