From 3b6ddf4b140befd1286af26c34800a50b3ba3f56 Mon Sep 17 00:00:00 2001 From: Carl Hetherington Date: Thu, 26 Sep 2013 00:38:43 +0100 Subject: Use xpath for node_children. --- test/tests.cc | 4 ++++ 1 file changed, 4 insertions(+) (limited to 'test/tests.cc') diff --git a/test/tests.cc b/test/tests.cc index 4bf0ae7..ed8d2f4 100644 --- a/test/tests.cc +++ b/test/tests.cc @@ -62,4 +62,8 @@ BOOST_AUTO_TEST_CASE (test) BOOST_CHECK_EQUAL (document.optional_bool_child("E").get(), true); BOOST_CHECK_THROW (document.optional_bool_child("F"), cxml::Error); BOOST_CHECK (!document.optional_bool_child("G")); + + BOOST_CHECK_EQUAL (document.node_children("F").size(), 2); + BOOST_CHECK_EQUAL (document.node_children("F").front()->content(), "1"); + BOOST_CHECK_EQUAL (document.node_children("F").back()->content(), "2"); } -- cgit v1.2.3