From d8c19b201f93dc070fb37472f933b53e49b393bc Mon Sep 17 00:00:00 2001 From: "arseny.kapoulkine" Date: Mon, 18 Oct 2010 18:27:13 +0000 Subject: Added xml_document::document_element function git-svn-id: http://pugixml.googlecode.com/svn/trunk@768 99668b35-9821-0410-8761-19e4c4f06640 --- tests/test_document.cpp | 10 ++++++++++ 1 file changed, 10 insertions(+) (limited to 'tests') diff --git a/tests/test_document.cpp b/tests/test_document.cpp index d6163e2..e424836 100644 --- a/tests/test_document.cpp +++ b/tests/test_document.cpp @@ -866,3 +866,13 @@ TEST(document_load_exceptions) CHECK(thrown); } #endif + +TEST_XML_FLAGS(document_element, "", parse_default | parse_declaration | parse_comments) +{ + CHECK(doc.document_element() == doc.child(STR("node"))); +} + +TEST_XML_FLAGS(document_element_absent, "", parse_comments) +{ + CHECK(doc.document_element() == xml_node()); +} -- cgit v1.2.3