+ test
This commit is contained in:
parent
b573841ace
commit
0ced78bfa8
2 changed files with 4 additions and 1 deletions
|
@ -1429,6 +1429,7 @@ bool JSON::iterator::operator==(const JSON::iterator& o) const
|
||||||
}
|
}
|
||||||
default:
|
default:
|
||||||
{
|
{
|
||||||
|
// not sure if used
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -1412,10 +1412,12 @@ TEST_CASE("Iterators")
|
||||||
CHECK(i4 == i4);
|
CHECK(i4 == i4);
|
||||||
}
|
}
|
||||||
{
|
{
|
||||||
JSON j_object = {{"1", 1}, {"2", 2}};
|
JSON j_object = {{"1", 1}, {"2", 2}, {"3", 3}};
|
||||||
|
|
||||||
JSON::iterator i1 = j_object.begin();
|
JSON::iterator i1 = j_object.begin();
|
||||||
++i1;
|
++i1;
|
||||||
|
JSON::iterator i11 = j_object.begin();
|
||||||
|
CHECK((i1 == i11) == false);
|
||||||
JSON::iterator i2(i1);
|
JSON::iterator i2(i1);
|
||||||
JSON::iterator i3;
|
JSON::iterator i3;
|
||||||
i3 = i2;
|
i3 = i2;
|
||||||
|
|
Loading…
Reference in a new issue