Back to index

nordugrid-arc-nox  1.1.0~rc6
Test.cpp
Go to the documentation of this file.
00001 #include <cppunit/CompilerOutputter.h>
00002 #include <cppunit/extensions/TestFactoryRegistry.h>
00003 #include <cppunit/ui/text/TestRunner.h>
00004 
00005 int main() {
00006   CppUnit::TextUi::TestRunner runner;
00007   runner.addTest(CppUnit::TestFactoryRegistry::getRegistry().makeTest());
00008 
00009   runner.setOutputter(CppUnit::CompilerOutputter::defaultOutputter
00010                     (&runner.result(), std::cerr));
00011 
00012   bool wasSuccessful = runner.run();
00013 
00014   return wasSuccessful ? 0 : 1;
00015 }