Example #1
0
void 
TestRunner::run( TestResult &controller,
                 const std::string &testPath )
{
  TestPath path = m_suite->resolveTestPath( testPath );
  Test *testToRun = path.getChildTest();

  controller.runTest( testToRun );
}
Example #2
0
Test *
Test::findTest( const std::string &testName ) const
{
  TestPath path;
  Test *mutableThis = CPPUNIT_CONST_CAST( Test *, this );
  mutableThis->findTestPath( testName, path );
  if ( !path.isValid() )
    throw std::invalid_argument( "No test named <" + testName + "> found in test <"
                                 + getName() + ">." );
  return path.getChildTest();
}