summaryrefslogtreecommitdiff
path: root/tests/test_xpath_api.cpp
diff options
context:
space:
mode:
authorArseny Kapoulkine <arseny.kapoulkine@gmail.com>2017-06-22 09:13:10 -0700
committerArseny Kapoulkine <arseny.kapoulkine@gmail.com>2017-06-22 09:13:10 -0700
commit2252927c04cc61c95a58cf4c3c47a0aac4b05b61 (patch)
tree2c7fe93906b158ce0a4ada9768357f97ad1c334a /tests/test_xpath_api.cpp
parent94ef7b3a033825c4bc3d3578b55f2349182745f0 (diff)
Deprecate xml_document::load(const char*) and xml_node::select_single_node
These functions were deprecated via comments in 1.5 but never got the deprecated attribute; now is the time! Using deprecated functions produces a warning; to silence it, this change moves the relevant tests to a separate translation unit that has deprecation disabled.
Diffstat (limited to 'tests/test_xpath_api.cpp')
-rw-r--r--tests/test_xpath_api.cpp11
1 files changed, 0 insertions, 11 deletions
diff --git a/tests/test_xpath_api.cpp b/tests/test_xpath_api.cpp
index 3f05e13..f933fb8 100644
--- a/tests/test_xpath_api.cpp
+++ b/tests/test_xpath_api.cpp
@@ -399,17 +399,6 @@ TEST_XML(xpath_api_node_set_assign_out_of_memory_preserve, "<node><a/><b/></node
CHECK(ns[0] == doc.child(STR("node")).child(STR("a")) && ns[1] == doc.child(STR("node")).child(STR("b")));
}
-TEST_XML(xpath_api_deprecated_select_single_node, "<node><head/><foo id='1'/><foo/><tail/></node>")
-{
- xpath_node n1 = doc.select_single_node(STR("node/foo"));
-
- xpath_query q(STR("node/foo"));
- xpath_node n2 = doc.select_single_node(q);
-
- CHECK(n1.node().attribute(STR("id")).as_int() == 1);
- CHECK(n2.node().attribute(STR("id")).as_int() == 1);
-}
-
TEST(xpath_api_empty)
{
xml_node c;