Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/miloyip/rapidjson.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authormiloyip <miloyip@gmail.com>2015-04-13 09:17:21 +0300
committermiloyip <miloyip@gmail.com>2015-04-13 09:17:21 +0300
commit3d82781a7539a14fe1f04d3d94f9e37eafb1a115 (patch)
tree55e54aece66ded45fd9daa817043c6683aaa22d8
parent127ce7175ab43bf83c334f2e3589f8bbadeee7c5 (diff)
Improve PrettyWriter coverage
-rw-r--r--test/unittest/prettywritertest.cpp8
1 files changed, 5 insertions, 3 deletions
diff --git a/test/unittest/prettywritertest.cpp b/test/unittest/prettywritertest.cpp
index 9be4f037..d0abf334 100644
--- a/test/unittest/prettywritertest.cpp
+++ b/test/unittest/prettywritertest.cpp
@@ -25,7 +25,7 @@
using namespace rapidjson;
-static const char kJson[] = "{\"hello\":\"world\",\"t\":true,\"f\":false,\"n\":null,\"i\":123,\"pi\":3.1416,\"a\":[1,2,3],\"u64\":1234567890123456789,\"i64\":-1234567890123456789}";
+static const char kJson[] = "{\"hello\":\"world\",\"t\":true,\"f\":false,\"n\":null,\"i\":123,\"pi\":3.1416,\"a\":[1,2,3,-1],\"u64\":1234567890123456789,\"i64\":-1234567890123456789}";
TEST(PrettyWriter, Basic) {
StringBuffer buffer;
@@ -44,7 +44,8 @@ TEST(PrettyWriter, Basic) {
" \"a\": [\n"
" 1,\n"
" 2,\n"
- " 3\n"
+ " 3,\n"
+ " -1\n"
" ],\n"
" \"u64\": 1234567890123456789,\n"
" \"i64\": -1234567890123456789\n"
@@ -70,7 +71,8 @@ TEST(PrettyWriter, SetIndent) {
"\t\"a\": [\n"
"\t\t1,\n"
"\t\t2,\n"
- "\t\t3\n"
+ "\t\t3,\n"
+ "\t\t-1\n"
"\t],\n"
"\t\"u64\": 1234567890123456789,\n"
"\t\"i64\": -1234567890123456789\n"