From f4dcfd65f2695fd2163109e6577fb61c524c9d5f Mon Sep 17 00:00:00 2001 From: joergkappes Date: Sat, 28 Mar 2015 18:20:06 +0100 Subject: fix memleaks in test --- tests/test_XMLDocument.cpp | 8 ++++++++ 1 file changed, 8 insertions(+) (limited to 'tests/test_XMLDocument.cpp') diff --git a/tests/test_XMLDocument.cpp b/tests/test_XMLDocument.cpp index 18e880d..95429cb 100644 --- a/tests/test_XMLDocument.cpp +++ b/tests/test_XMLDocument.cpp @@ -45,6 +45,9 @@ BOOST_AUTO_TEST_CASE( testXMLDocument_Constructor1 ) BOOST_CHECK(root.getName() == "test"); BOOST_CHECK(root.getContent().empty()); + + delete doc; + } BOOST_AUTO_TEST_CASE( testXMLDocument_FileIO ) @@ -61,6 +64,9 @@ BOOST_AUTO_TEST_CASE( testXMLDocument_FileIO ) BOOST_CHECK(root.getName() == "test"); BOOST_CHECK(root.getContent().empty()); + delete doc2; + delete doc; + } BOOST_AUTO_TEST_CASE( testXMLDocument_CreateNodes ) @@ -109,6 +115,8 @@ BOOST_AUTO_TEST_CASE( testXMLDocument_Options ) BOOST_CHECK(root.getOption("opt") == "val"); + delete doc; + } BOOST_AUTO_TEST_CASE( testXMLDocument_List ) -- cgit v1.2.3