| 29 | |
| 30 | |
| 31 | bool |
| 32 | Test::findTestPath( const std::string &testName, |
| 33 | TestPath &testPath ) const |
| 34 | { |
| 35 | Test *mutableThis = CPPUNIT_CONST_CAST( Test *, this ); |
| 36 | if ( getName() == testName ) |
| 37 | { |
| 38 | testPath.add( mutableThis ); |
| 39 | return true; |
| 40 | } |
| 41 | |
| 42 | int childCount = getChildTestCount(); |
| 43 | for ( int childIndex =0; childIndex < childCount; ++childIndex ) |
| 44 | { |
| 45 | if ( getChildTestAt( childIndex )->findTestPath( testName, testPath ) ) |
| 46 | { |
| 47 | testPath.insert( mutableThis, 0 ); |
| 48 | return true; |
| 49 | } |
| 50 | } |
| 51 | |
| 52 | return false; |
| 53 | } |
| 54 | |
| 55 | |
| 56 | bool |