📄 class_test.html
字号:
</tr> <tr> <td class="md" nowrap align="right"></td> <td></td> <td class="md" nowrap><a class="el" href="class_test_path.html">TestPath</a> & </td> <td class="mdname" nowrap> <em>testPath</em></td> </tr> <tr> <td></td> <td class="md">) </td> <td class="md" colspan="2"> const<code> [virtual]</code></td> </tr> </table> </td> </tr></table><table cellspacing=5 cellpadding=0 border=0> <tr> <td> </td> <td><p>Finds the specified test and its parents test. <p><dl compact><dt><b>Parameters:</b></dt><dd> <table border="0" cellspacing="2" cellpadding="0"> <tr><td></td><td valign=top><em>test</em> </td><td>Test to find. </td></tr> <tr><td></td><td valign=top><em>testPath</em> </td><td>If the test is found, then all the tests traversed to access <em>test</em> are added to <em>testPath</em>, including <code>this</code> and <em>test</em>. </td></tr> </table></dl><dl compact><dt><b>Returns:</b></dt><dd><code>true</code> if the specified test is found, <code>false</code> otherwise. </dd></dl> </td> </tr></table><a class="anchor" name="a6" doxytag="Test::findTestPath" ></a><p><table class="mdTable" width="100%" cellpadding="2" cellspacing="0"> <tr> <td class="mdRow"> <table cellpadding="0" cellspacing="0" border="0"> <tr> <td class="md" nowrap valign="top"> bool Test::findTestPath </td> <td class="md" valign="top">( </td> <td class="md" nowrap valign="top">const std::string & </td> <td class="mdname" nowrap> <em>testName</em>, </td> </tr> <tr> <td class="md" nowrap align="right"></td> <td></td> <td class="md" nowrap><a class="el" href="class_test_path.html">TestPath</a> & </td> <td class="mdname" nowrap> <em>testPath</em></td> </tr> <tr> <td></td> <td class="md">) </td> <td class="md" colspan="2"> const<code> [virtual]</code></td> </tr> </table> </td> </tr></table><table cellspacing=5 cellpadding=0 border=0> <tr> <td> </td> <td><p>Finds the test with the specified name and its parents test. <p><dl compact><dt><b>Parameters:</b></dt><dd> <table border="0" cellspacing="2" cellpadding="0"> <tr><td></td><td valign=top><em>testName</em> </td><td>Name of the test to find. </td></tr> <tr><td></td><td valign=top><em>testPath</em> </td><td>If the test is found, then all the tests traversed to access <em>test</em> are added to <em>testPath</em>, including <code>this</code> and <em>test</em>. </td></tr> </table></dl><dl compact><dt><b>Returns:</b></dt><dd><code>true</code> if a test with the specified name is found, <code>false</code> otherwise. </dd></dl> </td> </tr></table><a class="anchor" name="a4" doxytag="Test::getChildTestAt" ></a><p><table class="mdTable" width="100%" cellpadding="2" cellspacing="0"> <tr> <td class="mdRow"> <table cellpadding="0" cellspacing="0" border="0"> <tr> <td class="md" nowrap valign="top"> CPPUNIT_NS_BEGIN <a class="el" href="class_test.html">Test</a> * Test::getChildTestAt </td> <td class="md" valign="top">( </td> <td class="md" nowrap valign="top">int </td> <td class="mdname1" valign="top" nowrap> <em>index</em> </td> <td class="md" valign="top"> ) </td> <td class="md" nowrap> const<code> [virtual]</code></td> </tr> </table> </td> </tr></table><table cellspacing=5 cellpadding=0 border=0> <tr> <td> </td> <td><p>Returns the child test of the specified index. <p>This method test if the index is valid, then call doGetChildTestAt() if the index is valid. Otherwise std::out_of_range exception is thrown.<p>You should override doGetChildTestAt() method.<p><dl compact><dt><b>Parameters:</b></dt><dd> <table border="0" cellspacing="2" cellpadding="0"> <tr><td></td><td valign=top><em>index</em> </td><td>Zero based index of the child test to return. </td></tr> </table></dl><dl compact><dt><b>Returns:</b></dt><dd>Pointer on the test. Never <code>NULL</code>. </dd></dl><dl compact><dt><b>Exceptions:</b></dt><dd> <table border="0" cellspacing="2" cellpadding="0"> <tr><td></td><td valign=top><em>std::out_of_range</em> </td><td>is <em>index</em> is < 0 or >= getChildTestCount(). </td></tr> </table></dl> </td> </tr></table><a class="anchor" name="a3" doxytag="Test::getChildTestCount" ></a><p><table class="mdTable" width="100%" cellpadding="2" cellspacing="0"> <tr> <td class="mdRow"> <table cellpadding="0" cellspacing="0" border="0"> <tr> <td class="md" nowrap valign="top"> virtual int Test::getChildTestCount </td> <td class="md" valign="top">( </td> <td class="mdname1" valign="top" nowrap> </td> <td class="md" valign="top"> ) </td> <td class="md" nowrap> const<code> [pure virtual]</code></td> </tr> </table> </td> </tr></table><table cellspacing=5 cellpadding=0 border=0> <tr> <td> </td> <td><p>Returns the number of direct child of the test. <p><p>Implemented in <a class="el" href="class_test_decorator.html#a5">TestDecorator</a>, <a class="el" href="class_test_leaf.html#a1">TestLeaf</a>, <a class="el" href="class_test_runner_1_1_wrapping_suite.html#a1">TestRunner::WrappingSuite</a>, and <a class="el" href="class_test_suite.html#a5">TestSuite</a>. </td> </tr></table><a class="anchor" name="a5" doxytag="Test::getName" ></a><p><table class="mdTable" width="100%" cellpadding="2" cellspacing="0"> <tr> <td class="mdRow"> <table cellpadding="0" cellspacing="0" border="0"> <tr> <td class="md" nowrap valign="top"> virtual std::string Test::getName </td> <td class="md" valign="top">( </td> <td class="mdname1" valign="top" nowrap> </td> <td class="md" valign="top"> ) </td> <td class="md" nowrap> const<code> [pure virtual]</code></td> </tr> </table> </td> </tr></table><table cellspacing=5 cellpadding=0 border=0> <tr> <td> </td> <td><p>Returns the test name. <p>Each test has a name. This name may be used to find the test in a suite or registry of tests. <p>Implemented in <a class="el" href="class_test_case_decorator.html#a2">TestCaseDecorator</a>, <a class="el" href="class_test_decorator.html#a3">TestDecorator</a>, <a class="el" href="class_test_case.html#a4">TestCase</a>, <a class="el" href="class_test_composite.html#a4">TestComposite</a>, and <a class="el" href="class_test_runner_1_1_wrapping_suite.html#a2">TestRunner::WrappingSuite</a>. </td> </tr></table><a class="anchor" name="a9" doxytag="Test::resolveTestPath" ></a><p><table class="mdTable" width="100%" cellpadding="2" cellspacing="0"> <tr> <td class="mdRow"> <table cellpadding="0" cellspacing="0" border="0"> <tr> <td class="md" nowrap valign="top"> <a class="el" href="class_test_path.html">TestPath</a> Test::resolveTestPath </td> <td class="md" valign="top">( </td> <td class="md" nowrap valign="top">const std::string & </td> <td class="mdname1" valign="top" nowrap> <em>testPath</em> </td> <td class="md" valign="top"> ) </td> <td class="md" nowrap> const<code> [virtual]</code></td> </tr> </table> </td> </tr></table><table cellspacing=5 cellpadding=0 border=0> <tr> <td> </td> <td><p>Resolved the specified test path with this test acting as 'root'. <p><dl compact><dt><b>Parameters:</b></dt><dd> <table border="0" cellspacing="2" cellpadding="0"> <tr><td></td><td valign=top><em>testPath</em> </td><td>Test path string to resolve. </td></tr> </table></dl><dl compact><dt><b>Returns:</b></dt><dd>Resolved <a class="el" href="class_test_path.html">TestPath</a>. </dd></dl><dl compact><dt><b>Exceptions:</b></dt><dd> <table border="0" cellspacing="2" cellpadding="0"> <tr><td></td><td valign=top><em>std::invalid_argument</em> </td><td>if <em>testPath</em> could not be resolved. </td></tr> </table></dl><dl compact><dt><b>See also:</b></dt><dd><a class="el" href="class_test_path.html">TestPath</a>. </dd></dl> </td> </tr></table><a class="anchor" name="a1" doxytag="Test::run" ></a><p><table class="mdTable" width="100%" cellpadding="2" cellspacing="0"> <tr> <td class="mdRow"> <table cellpadding="0" cellspacing="0" border="0"> <tr> <td class="md" nowrap valign="top"> virtual void Test::run </td> <td class="md" valign="top">( </td> <td class="md" nowrap valign="top"><a class="el" href="class_test_result.html">TestResult</a> * </td> <td class="mdname1" valign="top" nowrap> <em>result</em> </td> <td class="md" valign="top"> ) </td> <td class="md" nowrap><code> [pure virtual]</code></td> </tr> </table> </td> </tr></table><table cellspacing=5 cellpadding=0 border=0> <tr> <td> </td> <td><p>Run the test, collecting results. <p><p>Implemented in <a class="el" href="class_repeated_test.html#a1">RepeatedTest</a>, <a class="el" href="class_test_decorator.html#a4">TestDecorator</a>, <a class="el" href="class_test_set_up.html#a1">TestSetUp</a>, <a class="el" href="class_test_case.html#a3">TestCase</a>, <a class="el" href="class_test_composite.html#a2">TestComposite</a>, and <a class="el" href="class_test_runner_1_1_wrapping_suite.html#a3">TestRunner::WrappingSuite</a>. </td> </tr></table><hr>The documentation for this class was generated from the following files:<ul><li><a class="el" href="_test_8h-source.html">Test.h</a><li><a class="el" href="_test_8cpp.html">Test.cpp</a></ul><hr><table width="100%"> <tr> <td width="10%" align="left" valign="center"> <a href="http://sourceforge.net"> <img src="http://sourceforge.net/sflogo.php?group_id=11795" width="88" height="31" border="0" alt="SourceForge Logo"></a> </td> <td width="20%" align="left" valign="center"> hosts this site. </td> <td> </td> <td align="right" valign="center"> Send comments to:<br> <a href="mailto:cppunit-devel@lists.sourceforge.net">CppUnit Developers</a> </td> </tr></table></body> </html>
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -