summaryrefslogtreecommitdiff
path: root/tests/test_dom_text.cpp
diff options
context:
space:
mode:
authorArseny Kapoulkine <arseny.kapoulkine@gmail.com>2015-01-16 21:48:50 -0800
committerArseny Kapoulkine <arseny.kapoulkine@gmail.com>2015-01-16 21:48:50 -0800
commite5ecbd63ce75de0a8f1473cbe0c1f9eea657dd02 (patch)
tree8ace0fd644cc3c8274c1e74f2b0743d21a957441 /tests/test_dom_text.cpp
parent93c3ab46494f35c390b40220519d83634e4e347f (diff)
parent8e95f0d88947631162f5ed1fc5427b414425604b (diff)
Merge branch 'master' into compact
Diffstat (limited to 'tests/test_dom_text.cpp')
-rw-r--r--tests/test_dom_text.cpp14
1 files changed, 10 insertions, 4 deletions
diff --git a/tests/test_dom_text.cpp b/tests/test_dom_text.cpp
index fb65b03..007334a 100644
--- a/tests/test_dom_text.cpp
+++ b/tests/test_dom_text.cpp
@@ -263,10 +263,13 @@ TEST_XML(dom_text_assign, "<node/>")
node.append_child(STR("text6")).text() = 0.5;
xml_text() = 0.5;
- node.append_child(STR("text7")).text() = true;
+ node.append_child(STR("text7")).text() = 0.25f;
+ xml_text() = 0.25f;
+
+ node.append_child(STR("text8")).text() = true;
xml_text() = true;
- CHECK_NODE(node, STR("<node><text1>v1</text1><text2>-2147483647</text2><text3>-2147483648</text3><text4>4294967295</text4><text5>4294967294</text5><text6>0.5</text6><text7>true</text7></node>"));
+ CHECK_NODE(node, STR("<node><text1>v1</text1><text2>-2147483647</text2><text3>-2147483648</text3><text4>4294967295</text4><text5>4294967294</text5><text6>0.5</text6><text7>0.25</text7><text8>true</text8></node>"));
}
TEST_XML(dom_text_set_value, "<node/>")
@@ -287,10 +290,13 @@ TEST_XML(dom_text_set_value, "<node/>")
CHECK(node.append_child(STR("text6")).text().set(0.5));
CHECK(!xml_text().set(0.5));
- CHECK(node.append_child(STR("text7")).text().set(true));
+ CHECK(node.append_child(STR("text7")).text().set(0.25f));
+ CHECK(!xml_text().set(0.25f));
+
+ CHECK(node.append_child(STR("text8")).text().set(true));
CHECK(!xml_text().set(true));
- CHECK_NODE(node, STR("<node><text1>v1</text1><text2>-2147483647</text2><text3>-2147483648</text3><text4>4294967295</text4><text5>4294967294</text5><text6>0.5</text6><text7>true</text7></node>"));
+ CHECK_NODE(node, STR("<node><text1>v1</text1><text2>-2147483647</text2><text3>-2147483648</text3><text4>4294967295</text4><text5>4294967294</text5><text6>0.5</text6><text7>0.25</text7><text8>true</text8></node>"));
}
#ifdef PUGIXML_HAS_LONG_LONG