REQUIRE(std::string(t) == "text\n");
}
SECTION("child")
SECTION("tag")
{
const auto t = element {
child {},
tag {},
};
REQUIRE(std::string(t) == "<child>\n</child>\n");
REQUIRE(std::string(t) == "<tag>\n</tag>\n");
}
SECTION("child element")
SECTION("tag element")
{
const auto t = child {
const auto t = tag {
element {},
};
REQUIRE(std::string(t) == "<child>\n</child>\n");
REQUIRE(std::string(t) == "<tag>\n</tag>\n");
}
SECTION("element child data")
SECTION("element tag")
{
const auto t = element {
child {"text"},
tag {},
};
REQUIRE(std::string(t) == "<child>\n text\n</child>\n");
REQUIRE(std::string(t) == "<tag>\n</tag>\n");
}
SECTION("child element data")
SECTION("element tag data")
{
const auto t = child {
const auto t = element {
tag {"text"},
};
REQUIRE(std::string(t) == "<tag>text</tag>\n");
}
SECTION("tag element data")
{
const auto t = tag {
element {"text"},
};
REQUIRE(std::string(t) == "<tag>text</tag>\n");
}
SECTION("tag element data")
{
const auto t = tag {
element {"text"},
};
REQUIRE(std::string(t) == "<child>\n text\n</child>\n");
REQUIRE(std::string(t) == "<tag>text</tag>\n");
}
SECTION("element tag child data")
{
const auto t = element {
tag {
child {
"text",
},
},
};
REQUIRE(std::string(t) == "<tag>\n <child>text</child>\n</tag>\n");
}
SECTION("element tag element child data")
{
const auto t = element {
tag {
element {
child {
"text",
},
},
},
};
REQUIRE(std::string(t) == "<tag>\n <child>text</child>\n</tag>\n");
}
SECTION("element tag child element data")
{
const auto t = element {
tag {
child {
element {
"text",
},
},
},
};
REQUIRE(std::string(t) == "<tag>\n <child>text</child>\n</tag>\n");
}
SECTION("element tag element child element data")
{
const auto t = element {
tag {
element {
child {
element {
"text",
},
},
},
},
};
REQUIRE(std::string(t) == "<tag>\n <child>text</child>\n</tag>\n");
}
SECTION("tag element child data")
{
const auto t = tag {
element {
child {
"text",
},
},
};
REQUIRE(std::string(t) == "<tag>\n <child>text</child>\n</tag>\n");
}
SECTION("tag child element data")
{
const auto t = tag {
child {
element {
"text",
},
},
};
REQUIRE(std::string(t) == "<tag>\n <child>text</child>\n</tag>\n");
}
SECTION("tag element child element data")
{
const auto t = tag {
element {
child {
element {
"text",
},
},
},
};
REQUIRE(std::string(t) == "<tag>\n <child>text</child>\n</tag>\n");
}
}