mirror of
https://github.com/nlohmann/json.git
synced 2026-10-05 22:20:30 +00:00
@@ -1765,8 +1765,8 @@ TEST_CASE("std::optional")
|
|||||||
{
|
{
|
||||||
SECTION("null")
|
SECTION("null")
|
||||||
{
|
{
|
||||||
json j_null;
|
const json j_null;
|
||||||
std::optional<std::string> opt_null;
|
const std::optional<std::string> opt_null;
|
||||||
|
|
||||||
CHECK(json(opt_null) == j_null);
|
CHECK(json(opt_null) == j_null);
|
||||||
CHECK(j_null.get<std::optional<std::string>>() == std::nullopt);
|
CHECK(j_null.get<std::optional<std::string>>() == std::nullopt);
|
||||||
|
|||||||
Reference in New Issue
Block a user