CppUnit::Test* ObjectPoolTest::suite()
{
	CppUnit::TestSuite* suiteOfTests = new CppUnit::TestSuite("ObjectPoolTest");
	suiteOfTests->addTest( new CppUnit::TestCaller<ObjectPoolTest>( 
		"testSimple", 
		&ObjectPoolTest::testSimple ) );

	suiteOfTests->addTest( new CppUnit::TestCaller<ObjectPoolTest>( 
		"testCreation", 
		&ObjectPoolTest::testCreation ) );

	suiteOfTests->addTest( new CppUnit::TestCaller<ObjectPoolTest>( 
		"testInvalidChunkSize", 
		&ObjectPoolTest::testInvalidChunkSize ) );

	suiteOfTests->addTest( new CppUnit::TestCaller<ObjectPoolTest>( 
		"testAcquire", 
		&ObjectPoolTest::testAcquire ) );

	suiteOfTests->addTest( new CppUnit::TestCaller<ObjectPoolTest>( 
		"testExclusivity", 
		&ObjectPoolTest::testExclusivity ) );

	suiteOfTests->addTest( new CppUnit::TestCaller<ObjectPoolTest>( 
		"testRelease", 
		&ObjectPoolTest::testRelease ) );
	return suiteOfTests;
}
Esempio n. 2
0
 static CppUnit::Test *suite()
 {
   CppUnit::TestSuite *suiteOfTests = new CppUnit::TestSuite( "JTSArray4MessageTest" );
   
   suiteOfTests->addTest( new CppUnit::TestCaller<JTSArray4MessageTest>( 
                                  "testConstructionDefaults", 
                                  &JTSArray4MessageTest::testConstructionDefaults ) );
                                  
   suiteOfTests->addTest( new CppUnit::TestCaller<JTSArray4MessageTest>( 
                                  "testSetGetOperations (TP_3.3.5.1)", 
                                  &JTSArray4MessageTest::testSetGetOperations ) );
                                  
   suiteOfTests->addTest( new CppUnit::TestCaller<JTSArray4MessageTest>( 
                                  "testEncodeToSpec (TP_3.3.5.2)", 
                                  &JTSArray4MessageTest::testEncodeToSpec ) );
                                  
   suiteOfTests->addTest( new CppUnit::TestCaller<JTSArray4MessageTest>( 
                                  "testEncodeDecodeOperations (TP_3.3.5.3)", 
                                  &JTSArray4MessageTest::testEncodeDecodeOperations ) );                                   
                                                                     
   suiteOfTests->addTest( new CppUnit::TestCaller<JTSArray4MessageTest>( 
                                  "testEquality", 
                                  &JTSArray4MessageTest::testEquality ) );
                                  
   suiteOfTests->addTest( new CppUnit::TestCaller<JTSArray4MessageTest>(
                                  "testInequality",
                                  &JTSArray4MessageTest::testInequality ) );
   return suiteOfTests;
 }
CppUnit::Test * ind_withIDTest::suite()
{
  CppUnit::TestSuite *suiteOfTests = new CppUnit::TestSuite( "ind_withIDTest"  );
  suiteOfTests->addTest( 
			new CppUnit::TestCaller<ind_withIDTest>(
								"testNonmemPars_h", 
								&ind_withIDTest::testNonmemPars_h ) );
  suiteOfTests->addTest( 
			new CppUnit::TestCaller<ind_withIDTest>(
								"testIndDataClass", 
								&ind_withIDTest::testIndDataClass ) );
  suiteOfTests->addTest( 
			new CppUnit::TestCaller<ind_withIDTest>(
								"testDataSetClass", 
								&ind_withIDTest::testDataSetClass ) );
  suiteOfTests->addTest( 
			new CppUnit::TestCaller<ind_withIDTest>(
								"testPredClass", 
								&ind_withIDTest::testPredClass ) );
  suiteOfTests->addTest( 
			new CppUnit::TestCaller<ind_withIDTest>(
								"testDriver", 
								&ind_withIDTest::testDriver ) );
  suiteOfTests->addTest( 
			new CppUnit::TestCaller<ind_withIDTest>(
								"testReportML", 
								&ind_withIDTest::testReportML ) );
  return suiteOfTests;
}
CppUnit::Test* LoggingTestSuite::suite()
{
	CppUnit::TestSuite* pSuite = new CppUnit::TestSuite("LoggingTestSuite");

	pSuite->addTest(LoggerTest::suite());
	pSuite->addTest(ChannelTest::suite());
	pSuite->addTest(PatternFormatterTest::suite());
	pSuite->addTest(FileChannelTest::suite());
	pSuite->addTest(SimpleFileChannelTest::suite());
	pSuite->addTest(LoggingFactoryTest::suite());
	pSuite->addTest(LoggingRegistryTest::suite());
	pSuite->addTest(LogStreamTest::suite());

	return pSuite;
}
Esempio n. 5
0
void getNames(vector<string>& names, const std::vector<TestPtr> &vTests)
{
  for (size_t i = 0; i < vTests.size(); i++)
  {
    // See if our test is really a suite
    CppUnit::TestSuite* suite = dynamic_cast<CppUnit::TestSuite*>(vTests[i].get());
    if (suite != 0)
    {
      vector<CppUnit::Test*> children = suite->getTests();
      for (size_t j = 0; j < children.size(); ++j)
      {
        getNames(names, children[j]);
      }
    }
    else
    {
      names.push_back(vTests[i]->getName());
    }
  }
}
Esempio n. 6
0
CppUnit::TestSuite *ABTMessageTest::getSuite(void)
{
     CppUnit::TestSuite          *suite = new CppUnit::TestSuite();
     suite->addTest(
        new CppUnit::TestCaller<ABTMessageTest>(
            "ABTMessageTest::test_constructor",
            &ABTMessageTest::test_constructor));
    
    suite->addTest(
        new CppUnit::TestCaller<ABTMessageTest>(
            "ABTMessageTest::test_accessors",
            &ABTMessageTest::test_accessors));
    
    suite->addTest(
        new CppUnit::TestCaller<ABTMessageTest>(
            "ABTMessageTest::test_xml",
            &ABTMessageTest::test_xml));

    return suite;
}
Esempio n. 7
0
/*! List all available tests in a given test suite. */
int ListAllTestsInTestSuite(CppUnit::Test* tests) {
    int count = 0;
    // try to see if this is a TestSuite
    CppUnit::TestSuite* testSuite = dynamic_cast<CppUnit::TestSuite *>(tests);
    // it's a suite, check all components
    if (testSuite != NULL) {
        std::vector<CppUnit::Test*> allTestsVector = testSuite->getTests();
        std::vector<CppUnit::Test*>::iterator testIterator;
        for (testIterator = allTestsVector.begin();
             testIterator != allTestsVector.end();
             testIterator++) {
            count += ListAllTestsInTestSuite(*testIterator);
        }
    } else {
        // it's a test, get the name
        count++;
        std::cout << tests->getName() << std::endl;
    }
    return count;
}
Esempio n. 8
0
int main(int argc, char* argv[])
{
// Get the top level suite from the registry
//CPPUNIT_NS::Test *suite = CPPUNIT_NS::TestFactoryRegistry::getRegistry().makeTest();
	CppUnit::TestSuite *unitSuite = new CppUnit::TestSuite( "All unit test" );
	unitSuite->addTest(CppUnit::TestFactoryRegistry::getRegistry("VarTableTest").makeTest());	
	unitSuite->addTest(CppUnit::TestFactoryRegistry::getRegistry("ProcTableTest").makeTest());
	unitSuite->addTest(CppUnit::TestFactoryRegistry::getRegistry("ModifiesTest").makeTest());
	unitSuite->addTest(CppUnit::TestFactoryRegistry::getRegistry("UsesTest").makeTest());	
	CppUnit::TestFactoryRegistry::getRegistry().addTestToSuite(unitSuite);
	CppUnit::TextUi::TestRunner runner;


	runner.addTest(unitSuite);
	bool wasSucessful = runner.run();

//cin.get();
getchar();

return wasSucessful ? 0 : 1;
}
Esempio n. 9
0
CppUnit::Test * InstantiateTests(const cisstTestParameters::TestNameContainerType & testNames)
{
    CppUnit::Test * wholeRegistry = CppUnit::TestFactoryRegistry::getRegistry().makeTest();
    if (testNames.empty())
        return wholeRegistry;

    CppUnit::TestSuite * testSuite = new CppUnit::TestSuite("");
    cisstTestParameters::TestNameContainerType::const_iterator nameIterator
        = testNames.begin();
    while (nameIterator != testNames.end()) {
        CppUnit::Test * test = FindTestInTestSuite(wholeRegistry, (*nameIterator));
        if (test != NULL) {
            testSuite->addTest(test);
        } else {
            std::cerr << "Failed to instantiate " << (*nameIterator) << std::endl;
        }

        ++nameIterator;
    }
    return testSuite;
}
int main(int argc, char** argv)
{
	CppUnit::TestSuite suite;

//	FrontSparcTest fst("FrontSparcTest");
//	  FrontendTest fet("FrontendTest");
//	FrontPentTest fpt("FrontPentTest");
	FrontPentTest fSt("FrontPentTest");

//	fst.registerTests(&suite);
//	fpt.registerTests(&suite);
	fSt.registerTests(&suite);

	CppUnit::TextTestResult res;

	prog.readLibParams();		 // Read library signatures (once!)
	suite.run( &res );
	std::cout << res << std::endl;

	return 0;
}
Esempio n. 11
0
CppUnit::Test* TriangleTestFixture::suite()
{
	// Create test suite
	CppUnit::TestSuite* suiteOfTests = new CppUnit::TestSuite("Triangle Tests");

	auto testFixture = new TriangleTestFixture();

	// Add tests
	suiteOfTests->addTest(new CppUnit::TestCaller<TriangleTestFixture>(
		"testEquality", &TriangleTestFixture::testIdentification, testFixture));

	suiteOfTests->addTest(new CppUnit::TestCaller<TriangleTestFixture>(
		"predicateTesting", &TriangleTestFixture::predicateTesting, testFixture));

	suiteOfTests->addTest(new CppUnit::TestCaller<TriangleTestFixture>(
		"negativeTesting", &TriangleTestFixture::negativeTesting, testFixture));

	//delete testFixture;

	return suiteOfTests;
}
Esempio n. 12
0
CppUnit::Test* SocketsTestSuite::suite()
{
    CppUnit::TestSuite* pSuite = new CppUnit::TestSuite("SocketsTestSuite");

    pSuite->addTest(SocketTest::suite());
    pSuite->addTest(SocketStreamTest::suite());
    pSuite->addTest(DatagramSocketTest::suite());
    pSuite->addTest(NetworkInterfaceTest::suite());
    pSuite->addTest(MulticastSocketTest::suite());
    pSuite->addTest(DialogSocketTest::suite());
    pSuite->addTest(RawSocketTest::suite());

    return pSuite;
}
Esempio n. 13
0
CppUnit::Test *SharedQueueTest::suite() {
    // Create a ConcurrencyComposite to act as our test suite.   Each test added to the composite will
    // be run in its own thread.

    ConcurrencyComposite *composite = new ConcurrencyComposite("SharedQueueTest");

    // Create 10 consumer threads.   Each thread will do a testPop followed by a testTryPop 100 times
    // before returning.

    for (int i = 0; i < 10; ++i) {
        CppUnit::TestSuite *consumer = new CppUnit::TestSuite();

        consumer->addTest(new CppUnit::TestCaller<SharedQueueTest>("testPop", &SharedQueueTest::testPop));
        //consumer->addTest(new CppUnit::TestCaller<SharedQueueTest>("testPop", &SharedQueueTest::testPop));
        consumer->addTest(new CppUnit::TestCaller<SharedQueueTest>("testTryPop", &SharedQueueTest::testTryPop));

        composite->addTest(new RepetitionDecorator(consumer, 100));
    }

    // Now create 10 producer threads.   Each thread will do a testPush followed by a testTryPush 100 times
    // before returning.

    for (int i = 0; i < 10; ++i) {
        CppUnit::TestSuite *producer = new CppUnit::TestSuite();

        producer->addTest(new CppUnit::TestCaller<SharedQueueTest>("testPush", &SharedQueueTest::testPush));
        producer->addTest(new CppUnit::TestCaller<SharedQueueTest>("testTryPush", &SharedQueueTest::testTryPush));

        composite->addTest(new RepetitionDecorator(producer, 100));
    }

    return composite;
}
Esempio n. 14
0
CppUnit::Test* TestPottsSpin::suite()
{
    CppUnit::TestSuite *suiteOfTests = new CppUnit::TestSuite("TestPottsSpin");
    
    suiteOfTests->addTest( new CppUnit::TestCaller<TestPottsSpin>("TestPottsSpin: test_constructor", &TestPottsSpin::test_constructor ) );

    suiteOfTests->addTest( new CppUnit::TestCaller<TestPottsSpin>("TestPottsSpin: test_get_set_value", &TestPottsSpin::test_get_set_value ) );
    suiteOfTests->addTest( new CppUnit::TestCaller<TestPottsSpin>("TestPottsSpin: test_get_set_max_value", &TestPottsSpin::test_get_set_max_value ) );

    suiteOfTests->addTest( new CppUnit::TestCaller<TestPottsSpin>("TestPottsSpin: test_operator_equal", &TestPottsSpin::test_operator_equal ) );
    suiteOfTests->addTest( new CppUnit::TestCaller<TestPottsSpin>("TestPottsSpin: test_operator_multiply", &TestPottsSpin::test_operator_multiply ) );

    suiteOfTests->addTest( new CppUnit::TestCaller<TestPottsSpin>("TestPottsSpin: test_all_possible_values", &TestPottsSpin::test_all_possible_values ) );
    suiteOfTests->addTest( new CppUnit::TestCaller<TestPottsSpin>("TestPottsSpin: test_random", &TestPottsSpin::test_random ) );
    suiteOfTests->addTest( new CppUnit::TestCaller<TestPottsSpin>("TestPottsSpin: test_random_differ", &TestPottsSpin::test_random_differ ) );

    return suiteOfTests;
}
Esempio n. 15
0
    static CppUnit::Test *suite()
    {
      CppUnit::TestSuite *suiteOfTests = new CppUnit::TestSuite("GraphTest");

      suiteOfTests->addTest(new CppUnit::TestCaller<GraphTest>("graphInsertTest", &GraphTest::graphInsertTest));
      suiteOfTests->addTest(new CppUnit::TestCaller<GraphTest>("diGraphInsertTest", &GraphTest::diGraphInsertTest));
      suiteOfTests->addTest(new CppUnit::TestCaller<GraphTest>("completeGraphTest", &GraphTest::completeGraphTest));
      suiteOfTests->addTest(new CppUnit::TestCaller<GraphTest>("findTest", &GraphTest::findTest));
      suiteOfTests->addTest(new CppUnit::TestCaller<GraphTest>("traversalTest", &GraphTest::traversalTest));
      suiteOfTests->addTest(new CppUnit::TestCaller<GraphTest>("iteratorTest", &GraphTest::iteratorTest));
      suiteOfTests->addTest(new CppUnit::TestCaller<GraphTest>("printTest", &GraphTest::printTest));
      suiteOfTests->addTest(new CppUnit::TestCaller<GraphTest>("printPrunerTest", &GraphTest::printPrunerTest));

      return suiteOfTests;
    }
Esempio n. 16
0
CppUnit::Test* DateTimeTestSuite::suite()
{
	CppUnit::TestSuite* pSuite = new CppUnit::TestSuite("DateTimeTestSuite");

	pSuite->addTest(TimestampTest::suite());
	pSuite->addTest(ClockTest::suite());
	pSuite->addTest(TimespanTest::suite());
	pSuite->addTest(TimezoneTest::suite());
	pSuite->addTest(DateTimeTest::suite());
	pSuite->addTest(LocalDateTimeTest::suite());
	pSuite->addTest(DateTimeFormatterTest::suite());
	pSuite->addTest(DateTimeParserTest::suite());

	return pSuite;
}
Esempio n. 17
0
CppUnit::Test* TestHistogram::suite()
{
    CppUnit::TestSuite *suiteOfTests = new CppUnit::TestSuite("TestHistograms/TestHistogram");
    
    suiteOfTests->addTest( new CppUnit::TestCaller<TestHistogram>("TestHistograms/TestHistogram: test_operator_fill", &TestHistogram::test_operator_fill ) );
    suiteOfTests->addTest( new CppUnit::TestCaller<TestHistogram>("TestHistograms/TestHistogram: test_operator_access", &TestHistogram::test_operator_access ) );
    suiteOfTests->addTest( new CppUnit::TestCaller<TestHistogram>("TestHistograms/TestHistogram: test_operator_increment", &TestHistogram::test_operator_increment ) );
    suiteOfTests->addTest( new CppUnit::TestCaller<TestHistogram>("TestHistograms/TestHistogram: test_operator_divide", &TestHistogram::test_operator_divide ) );

    suiteOfTests->addTest( new CppUnit::TestCaller<TestHistogram>("TestHistograms/TestHistogram: test_initialise_empty", &TestHistogram::test_initialise_empty ) );
    suiteOfTests->addTest( new CppUnit::TestCaller<TestHistogram>("TestHistograms/TestHistogram: test_insert", &TestHistogram::test_insert ) );
    suiteOfTests->addTest( new CppUnit::TestCaller<TestHistogram>("TestHistograms/TestHistogram: test_serialize", &TestHistogram::test_serialize ) );

    return suiteOfTests;
}
Esempio n. 18
0
CppUnit::Test* findTest(CppUnit::Test* t, std::string name)
{
  if (name == t->getName())
  {
    return t;
  }

  CppUnit::TestSuite* suite = dynamic_cast<CppUnit::TestSuite*>(t);
  if (suite != 0)
  {
    vector<CppUnit::Test*> children = suite->getTests();
    for (size_t i = 0; i < children.size(); ++i)
    {
      CppUnit::Test* result = findTest(children[i], name);
      if (result != 0)
      {
        return result;
      }
    }
  }

  return NULL;
}
Esempio n. 19
0
CppUnit::Test* TextTestSuite::suite()
{
	CppUnit::TestSuite* pSuite = new CppUnit::TestSuite("TextTestSuite");

	pSuite->addTest(TextIteratorTest::suite());
	pSuite->addTest(TextBufferIteratorTest::suite());
	pSuite->addTest(TextConverterTest::suite());
	pSuite->addTest(StreamConverterTest::suite());
	pSuite->addTest(TextEncodingTest::suite());
	pSuite->addTest(UTF8StringTest::suite());
#ifndef POCO_NO_WSTRING
	pSuite->addTest(UnicodeConverterTest::suite());
#endif

	return pSuite;
}
Esempio n. 20
0
CppUnit::Test *DestructionTest2::suite(void)
{	
	typedef BThreadedTestCaller<DestructionTest2> DestructionTest2Caller;
	CppUnit::TestSuite *testSuite = new CppUnit::TestSuite("DestructionTest2");
	
	// Make a benaphore based test object, create a ThreadedTestCase for it and add
	// two threads to it.
	DestructionTest2 *theTest = new DestructionTest2("Benaphore", true);
	DestructionTest2Caller *threadedTest1 = new DestructionTest2Caller("BLocker::Destruction Test #2 (benaphore)", theTest);
	threadedTest1->addThread("A", &DestructionTest2::TestThread1);
	threadedTest1->addThread("B", &DestructionTest2::TestThread2);
				
	// Make a semaphore based test object, create a ThreadedTestCase for it and add
	// three threads to it.					 		
	theTest = new DestructionTest2("Semaphore", false);
	DestructionTest2Caller *threadedTest2 = new DestructionTest2Caller("BLocker::Destruction Test #2 (semaphore)", theTest);
	threadedTest2->addThread("A", &DestructionTest2::TestThread1);
	threadedTest2->addThread("B", &DestructionTest2::TestThread2);
									 		
	testSuite->addTest(threadedTest1);	
	testSuite->addTest(threadedTest2);
	return(testSuite);
}
Esempio n. 21
0
CppUnit::Test* GetTest(CppUnit::Test* tests, const std::string& name)
{

  CppUnit::TestSuite* testSuite = dynamic_cast<CppUnit::TestSuite *>(tests);

  CppUnit::Test* returnTest = NULL;

  if (testSuite)
  {
    if (testSuite->getName() == name)
    {
      return (testSuite);
    }
    else
    {
      std::vector<CppUnit::Test*> allTests = testSuite->getTests();
      std::vector<CppUnit::Test*>::iterator testi;
      for (testi = allTests.begin();
           testi != allTests.end();
           testi++)
      {
        returnTest = GetTest(*testi, name);
        if (returnTest)
          return (returnTest);
      }
    }
  }
  else
  {
    if (tests->getName() == name)
    {
      return (tests);
    }
  }
  return NULL;
};
Esempio n. 22
0
CppUnit::Test* SocketsTestSuite::suite()
{
	CppUnit::TestSuite* pSuite = new CppUnit::TestSuite("SocketsTestSuite");

	pSuite->addTest(SocketTest::suite());
	pSuite->addTest(SocketStreamTest::suite());
	pSuite->addTest(DatagramSocketTest::suite());
	pSuite->addTest(DialogSocketTest::suite());
	pSuite->addTest(RawSocketTest::suite());
#ifdef POCO_NET_HAS_INTERFACE
	pSuite->addTest(MulticastSocketTest::suite());
#endif
	return pSuite;
}
Esempio n. 23
0
CppUnit::Test *
Pipeline_Run_Test::suite ()
{
  CppUnit::TestSuite *s = new CppUnit::TestSuite ("Pipeline run test");

  s->addTest (new CppUnit::TestCaller<Pipeline_Run_Test> ("1", &Pipeline_Run_Test::test_exit_logical_not));

  s->addTest (new CppUnit::TestCaller<Pipeline_Run_Test> ("2", &Pipeline_Run_Test::test_tar_ssh));

  s->addTest (new CppUnit::TestCaller<Pipeline_Run_Test> ("3", &Pipeline_Run_Test::test_ps_sort_less));
  s->addTest (new CppUnit::TestCaller<Pipeline_Run_Test> ("4", &Pipeline_Run_Test::test_tar));

  s->addTest (new CppUnit::TestCaller<Pipeline_Run_Test> ("5", &Pipeline_Run_Test::test_set_sighandler));

s->addTest (new CppUnit::TestCaller<Pipeline_Run_Test> ("6", &Pipeline_Run_Test::test_first_child_exit_success));
  s->addTest (new CppUnit::TestCaller<Pipeline_Run_Test> ("7", &Pipeline_Run_Test::test_first_child_exit_failure));

  s->addTest (new CppUnit::TestCaller<Pipeline_Run_Test> ("8", &Pipeline_Run_Test::test_str_assign_run_1));
  s->addTest (new CppUnit::TestCaller<Pipeline_Run_Test> ("9", &Pipeline_Run_Test::test_str_assign_run_2));

  return s;
}
CppUnit::Test *GJKConvexHullTest::suite()
{
	CppUnit::TestSuite *suite = new CppUnit::TestSuite("GJKConvexHullTest");

	suite->addTest(new CppUnit::TestCaller<GJKConvexHullTest>("identicalBox", &GJKConvexHullTest::identicalBox));
	suite->addTest(new CppUnit::TestCaller<GJKConvexHullTest>("separateBox", &GJKConvexHullTest::separateBox));
	suite->addTest(new CppUnit::TestCaller<GJKConvexHullTest>("cornerInsideBox", &GJKConvexHullTest::cornerInsideBox));

	suite->addTest(new CppUnit::TestCaller<GJKConvexHullTest>("faceInsideTrapeze", &GJKConvexHullTest::faceInsideTrapeze));

	suite->addTest(new CppUnit::TestCaller<GJKConvexHullTest>("separateHexagon", &GJKConvexHullTest::separateHexagon));
	suite->addTest(new CppUnit::TestCaller<GJKConvexHullTest>("cornerInsideHexagon", &GJKConvexHullTest::cornerInsideHexagon));

	return suite;
}
Esempio n. 25
0
CppUnit::Test* CryptTestSuite::suite()
{
	CppUnit::TestSuite* pSuite = new CppUnit::TestSuite("CryptTestTestSuite");

	pSuite->addTest(MD2EngineTest::suite());
	pSuite->addTest(MD4EngineTest::suite());
	pSuite->addTest(MD5EngineTest::suite());
	pSuite->addTest(SHA1EngineTest::suite());
	pSuite->addTest(HMACEngineTest::suite());
	pSuite->addTest(DigestStreamTest::suite());
	pSuite->addTest(RandomTest::suite());
	pSuite->addTest(RandomStreamTest::suite());

	return pSuite;
}
Esempio n. 26
0
CppUnit::Test* TextTestSuite::suite()
{
	CppUnit::TestSuite* pSuite = new CppUnit::TestSuite("TextTestSuite");

	pSuite->addTest(TextIteratorTest::suite());
	pSuite->addTest(TextConverterTest::suite());
	pSuite->addTest(StreamConverterTest::suite());
	pSuite->addTest(TextEncodingTest::suite());
	pSuite->addTest(UTF8StringTest::suite());
#ifdef _WINDOWS
	pSuite->addTest(UnicodeConverterTest::suite());
#endif

	return pSuite;
}
Esempio n. 27
0
CppUnit::Test* OptionsTestSuite::suite()
{
    CppUnit::TestSuite* pSuite = new CppUnit::TestSuite("OptionsTestSuite");

    pSuite->addTest(OptionTest::suite());
    pSuite->addTest(OptionSetTest::suite());
    pSuite->addTest(HelpFormatterTest::suite());
    pSuite->addTest(OptionProcessorTest::suite());
    pSuite->addTest(ValidatorTest::suite());

    return pSuite;
}
Esempio n. 28
0
CppUnit::Test *Lookup_Test::suite ()
{
  CppUnit::TestSuite *s = new CppUnit::TestSuite ("Lookup test");

  s->addTest (new CppUnit::TestCaller<Lookup_Test> ("1", &Lookup_Test::test_skip_space_1));
  s->addTest (new CppUnit::TestCaller<Lookup_Test> ("2", &Lookup_Test::test_char_lookup_1));
  s->addTest (new CppUnit::TestCaller<Lookup_Test> ("3", &Lookup_Test::test_digit_lookup_1));

  s->addTest (new CppUnit::TestCaller<Lookup_Test> ("4", &Lookup_Test::test_word_lookup_1));
  s->addTest (new CppUnit::TestCaller<Lookup_Test> ("5", &Lookup_Test::test_word_lookup_2));
  s->addTest (new CppUnit::TestCaller<Lookup_Test> ("6", &Lookup_Test::test_word_lookup_3));

  s->addTest (new CppUnit::TestCaller<Lookup_Test> ("7", &Lookup_Test::test_quote_lookup_1));
  s->addTest (new CppUnit::TestCaller<Lookup_Test> ("8", &Lookup_Test::test_quote_lookup_2));

  s->addTest (new CppUnit::TestCaller<Lookup_Test> ("9", &Lookup_Test::test_remove_backslash_1));

  return s;
}
Esempio n. 29
0
CppUnit::Test* TextTestSuite::suite()
{
	CppUnit::TestSuite* pSuite = new CppUnit::TestSuite("TextTestSuite");

	pSuite->addTest(TextIteratorTest::suite());
	pSuite->addTest(TextConverterTest::suite());
	pSuite->addTest(StreamConverterTest::suite());
	pSuite->addTest(TextEncodingTest::suite());
	pSuite->addTest(UTF8StringTest::suite());

	return pSuite;
}
CppUnit::Test *ShapeToConvexObjectTest::suite()
{
	CppUnit::TestSuite *suite = new CppUnit::TestSuite("ShapeToConvexObjectTest");

	suite->addTest(new CppUnit::TestCaller<ShapeToConvexObjectTest>("boxConversion", &ShapeToConvexObjectTest::boxConversion));
	suite->addTest(new CppUnit::TestCaller<ShapeToConvexObjectTest>("capsuleConversion", &ShapeToConvexObjectTest::capsuleConversion));
	suite->addTest(new CppUnit::TestCaller<ShapeToConvexObjectTest>("cylinderConversion", &ShapeToConvexObjectTest::cylinderConversion));
	suite->addTest(new CppUnit::TestCaller<ShapeToConvexObjectTest>("convexHullConversion", &ShapeToConvexObjectTest::convexHullConversion));
	suite->addTest(new CppUnit::TestCaller<ShapeToConvexObjectTest>("sphereConversion", &ShapeToConvexObjectTest::sphereConversion));

	return suite;
}