diff options
author | arseny.kapoulkine <arseny.kapoulkine@99668b35-9821-0410-8761-19e4c4f06640> | 2010-08-29 15:27:51 +0000 |
---|---|---|
committer | arseny.kapoulkine <arseny.kapoulkine@99668b35-9821-0410-8761-19e4c4f06640> | 2010-08-29 15:27:51 +0000 |
commit | e08c065820d734d4f5768470ed6a4f123cbb56ef (patch) | |
tree | c28a4c58b36cd0cd48841617a6a6fc3f8ce350df /tests/test.cpp | |
parent | 7554e206885a3f3aa1a771f0d4ca1d4a921994ad (diff) |
tests: Added XPath tests for attribute context
git-svn-id: http://pugixml.googlecode.com/svn/trunk@664 99668b35-9821-0410-8761-19e4c4f06640
Diffstat (limited to 'tests/test.cpp')
-rw-r--r-- | tests/test.cpp | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/tests/test.cpp b/tests/test.cpp index 96a81e4..9435f1e 100644 --- a/tests/test.cpp +++ b/tests/test.cpp @@ -54,7 +54,7 @@ bool test_node(const pugi::xml_node& node, const pugi::char_t* contents, const p } #ifndef PUGIXML_NO_XPATH -bool test_xpath_string(const pugi::xml_node& node, const pugi::char_t* query, const pugi::char_t* expected) +bool test_xpath_string(const pugi::xpath_node& node, const pugi::char_t* query, const pugi::char_t* expected) { pugi::xpath_query q(query); @@ -70,14 +70,14 @@ bool test_xpath_string(const pugi::xml_node& node, const pugi::char_t* query, co return q.evaluate_string(&buffer[0], size, node) == size && test_string_equal(buffer.c_str(), expected); } -bool test_xpath_boolean(const pugi::xml_node& node, const pugi::char_t* query, bool expected) +bool test_xpath_boolean(const pugi::xpath_node& node, const pugi::char_t* query, bool expected) { pugi::xpath_query q(query); return q.evaluate_boolean(node) == expected; } -bool test_xpath_number(const pugi::xml_node& node, const pugi::char_t* query, double expected) +bool test_xpath_number(const pugi::xpath_node& node, const pugi::char_t* query, double expected) { pugi::xpath_query q(query); @@ -88,7 +88,7 @@ bool test_xpath_number(const pugi::xml_node& node, const pugi::char_t* query, do return absolute_error < tolerance || absolute_error < fabs(expected) * tolerance; } -bool test_xpath_number_nan(const pugi::xml_node& node, const pugi::char_t* query) +bool test_xpath_number_nan(const pugi::xpath_node& node, const pugi::char_t* query) { pugi::xpath_query q(query); |