[json-glib: 2/3] tests: Add surrogate pair tests




commit cea6cb888065a89493d37a2d9b6805c00d592057
Author: James Westman <james flyingpimonster net>
Date:   Mon Nov 30 17:21:06 2020 -0600

    tests: Add surrogate pair tests

 json-glib/tests/invalid.c | 3 +++
 1 file changed, 3 insertions(+)
---
diff --git a/json-glib/tests/invalid.c b/json-glib/tests/invalid.c
index 0ab2d30..cb5f818 100644
--- a/json-glib/tests/invalid.c
+++ b/json-glib/tests/invalid.c
@@ -212,6 +212,9 @@ static const struct
 
   /* values */
   { "values-1", "[ -false ]", test_invalid_value },
+  { "values-2", "[\"\\uD800\\uD800\"]", test_invalid_value },
+  { "values-3", "[\"\\uDB00\\uD800\"]", test_invalid_value },
+  { "values-4", "[\"\\uDB00\"]", test_invalid_value },
 
   /* assignment */
   { "assignment-1", "var foo", test_invalid_assignment },


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]