diff options
Diffstat (limited to 'tests/test_write.cpp')
-rw-r--r-- | tests/test_write.cpp | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/tests/test_write.cpp b/tests/test_write.cpp index d5f3dad..5cd92a5 100644 --- a/tests/test_write.cpp +++ b/tests/test_write.cpp @@ -69,6 +69,12 @@ TEST_XML_FLAGS(write_cdata_escape, "<![CDATA[value]]>", parse_cdata | parse_frag doc.first_child().set_value(STR("1]]>2]]>3")); CHECK_NODE(doc, STR("<![CDATA[1]]]]><![CDATA[>2]]]]><![CDATA[>3]]>")); + + doc.first_child().set_value(STR("1]")); + CHECK_NODE(doc, STR("<![CDATA[1]]]>")); + + doc.first_child().set_value(STR("1]]")); + CHECK_NODE(doc, STR("<![CDATA[1]]]]>")); } TEST_XML(write_cdata_inner, "<node><![CDATA[value]]></node>") |