1
0
mirror of https://github.com/nlohmann/json synced 2024-11-30 07:30:06 +00:00

fixed build

This commit is contained in:
Niels 2015-08-02 21:40:25 +02:00
parent e64dc532ab
commit 9355dce063

View File

@ -7551,17 +7551,17 @@ TEST_CASE("iterator_wrapper")
{
SECTION("objects")
{
std::stringstream ss;
json j_object = {{"key1", 1}, {"key2", 2}};
for (auto it : json::iterator_wrapper(j_object))
{
CHECK((it.first == json("key1") or it.first == json("key2")));
CHECK((it.key() == json("key1") or it.key() == json("key2")));
CHECK(it.key() == it.first);
CHECK((it.second == json(1) or it.second == json(2)));
CHECK((it.value() == json(1) or it.value() == json(2)));
CHECK(it.value() == it.second);
ss << it.first << ' ';
ss << it.key() << ' ';
ss << it.second << ' ';
ss << it.value() << ' ';
}
CHECK(ss.str() == "key1 key1 1 1 key2 key2 2 2 ");
}
}