|
|
@ -10,6 +10,8 @@ |
|
|
|
#include <cppunit/ui/text/TestRunner.h> |
|
|
|
#include <cppunit/ui/text/TestRunner.h> |
|
|
|
#include <cppunit/extensions/HelperMacros.h> |
|
|
|
#include <cppunit/extensions/HelperMacros.h> |
|
|
|
#include <cppunit/extensions/TestFactoryRegistry.h> |
|
|
|
#include <cppunit/extensions/TestFactoryRegistry.h> |
|
|
|
|
|
|
|
#include <cppunit/XmlOutputter.h> |
|
|
|
|
|
|
|
#include <fstream> |
|
|
|
|
|
|
|
|
|
|
|
class A: public xml::Serialize { |
|
|
|
class A: public xml::Serialize { |
|
|
|
public: |
|
|
|
public: |
|
|
@ -163,8 +165,10 @@ class ContainerSerializationTest: public CppUnit::TestFixture { |
|
|
|
}; |
|
|
|
}; |
|
|
|
CPPUNIT_TEST_SUITE_REGISTRATION(ContainerSerializationTest); |
|
|
|
CPPUNIT_TEST_SUITE_REGISTRATION(ContainerSerializationTest); |
|
|
|
|
|
|
|
|
|
|
|
int main() try { |
|
|
|
int main(int argc, char** argv) try { |
|
|
|
|
|
|
|
std::ofstream ofs((*argv+std::string(".xml")).c_str()); |
|
|
|
CppUnit::TextUi::TestRunner runner; |
|
|
|
CppUnit::TextUi::TestRunner runner; |
|
|
|
|
|
|
|
runner.setOutputter(new CppUnit::XmlOutputter(&runner.result(), ofs)); |
|
|
|
runner.addTest(CppUnit::TestFactoryRegistry::getRegistry().makeTest()); |
|
|
|
runner.addTest(CppUnit::TestFactoryRegistry::getRegistry().makeTest()); |
|
|
|
return runner.run() ? 0 : 1; |
|
|
|
return runner.run() ? 0 : 1; |
|
|
|
} catch (std::exception& e) { |
|
|
|
} catch (std::exception& e) { |
|
|
|