Hello everybody,
CppUnit provides seperate TestRunner.h header for mfc and text . In case of MFC we can not set the out put as Xml . Has any body tried to make changes to cppUnit frame work to have out put as XML. or any work around ????
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
Hello everybody,
CppUnit provides seperate TestRunner.h header for mfc and text . In case of MFC we can not set the out put as Xml . Has any body tried to make changes to cppUnit frame work to have out put as XML. or any work around ????
// Create the event manager and test controller
CPPUNIT_NS::TestResult controller;
// Add a listener that colllects test result
CPPUNIT_NS::TestResultCollector result;
controller.addListener( &result );
CppUnit::TestRunner runner;
runner.addTest(XXX_TEST::suite());
runner.run(controller,"");
std::ofstream file( "results.xml" );
CPPUNIT_NS::XmlOutputter xml( &result, file );
//xml.setStyleSheet( "report.xsl" );
xml.write();
file.close();
This code is not working for me. Please can anyone help me? I need to generate a XML output in my MFC based app but don't know how.
thanks in advance.