aboutsummaryrefslogtreecommitdiffstats
path: root/tests
diff options
context:
space:
mode:
authoripknHama <ipknhama@gmail.com>2016-08-27 18:12:17 +0900
committeripknHama <ipknhama@gmail.com>2016-08-27 18:12:17 +0900
commitf88b56dff0e8adfbd654d0b39791c2664c863e07 (patch)
treee45e6f87f0a4564492fea7a339f71fda1614541e /tests
parente161da45e08a2eaaec747a784020d69f8223418d (diff)
downloadcrow-f88b56dff0e8adfbd654d0b39791c2664c863e07.tar.gz
crow-f88b56dff0e8adfbd654d0b39791c2664c863e07.zip
Add u() for uint64_t: manually applying #129
Diffstat (limited to 'tests')
-rw-r--r--tests/unittest.cpp4
1 files changed, 4 insertions, 0 deletions
diff --git a/tests/unittest.cpp b/tests/unittest.cpp
index 9021af5..78732b0 100644
--- a/tests/unittest.cpp
+++ b/tests/unittest.cpp
@@ -519,6 +519,10 @@ TEST(json_read)
ASSERT_EQUAL(false, z["bools"][1].b());
ASSERT_EQUAL(1.2, z["doubles"][0].d());
ASSERT_EQUAL(-3.4, z["doubles"][1].d());
+
+ std::string s3 = R"({"uint64": 18446744073709551615})";
+ auto z1 = json::load(s3);
+ ASSERT_EQUAL(18446744073709551615ull, z1["uint64"].u());
}
TEST(json_read_real)