Changeset 318

Show
Ignore:
Timestamp:
12/10/07 09:05:13 (10 months ago)
Author:
mrook
Message:

Fix out-of-date phpunit tasks documentation, add haltonincomplete/haltonskipped

Files:

Legend:

Unmodified
Added
Removed
Modified
Copied
Moved
  • branches/2.3/docs/phing_guide/book/chapters/appendixes/AppendixC-OptionalTasks.html

    r270 r318  
    249249  </fileset> 
    250250</coverage-setup> 
    251 <phpunit2 codecoverage="true"> 
     251<phpunit codecoverage="true"> 
    252252  <batchtest> 
    253253    <fileset dir="src"> 
     
    255255    </fileset> 
    256256  </batchtest> 
    257 </phpunit2> 
     257</phpunit> 
    258258</pre> 
    259259 
     
    699699  &lt;!-- xml formatter --&gt; 
    700700  &lt;formatter type=&quot;xml&quot; output=&quot;output.xml&quot;/&gt; 
    701    
     701 
    702702  &lt;!-- custom formatter --&gt; 
    703703  &lt;formatter classname=&quot;path.to.CustomFormatterClass&quot;&gt; 
     
    708708  &lt;formatter type=&quot;plain&quot; usefile=&quot;false&quot; /&gt;<br />&lt;/pdo&gt; 
    709709</pre> 
    710          
     710 
    711711  </li> 
    712712</ul> 
     
    10671067</pre> 
    10681068<p>Check syntax of a fileset of source files.</p> 
    1069 <h2><a name="PHPUnit2Task"></a>PHPUnit2Task</h2> 
    1070 <p>This task runs testcases using the <a href="http://www.phpunit.de/" target="_blank">PHPUnit2</a> framework. 
     1069<h2><a name="PHPUnitTask"></a>PHPUnitTask</h2> 
     1070<p>This task runs testcases using the <a href="http://www.phpunit.de/" target="_blank">PHPUnit</a> framework. 
    10711071It is a functional port of the Ant <a href="http://ant.apache.org/manual/OptionalTasks/junit.html" target="_blank">JUnit</a> task. 
    10721072</p> 
     1073<p><b>NB:</b> the identifiers <i>phpunit2</i> (PHPUnit2Task) and <i>phpunit3</i> (PHPUnit3Task) have been deprecated, but are still 
     1074available to maintain backwards compatibility.</p> 
    10731075<h3>Attributes</h3> 
    10741076<table> 
     
    10911093    </tr> 
    10921094    <tr> 
     1095      <td>codecoverage</td> 
     1096      <td>Boolean</td> 
     1097      <td> Gather code coverage information while running tests (requires Xdebug). </td> 
     1098      <td>false</td> 
     1099      <td>No</td> 
     1100    </tr> 
     1101    <tr> 
    10931102      <td>haltonerror</td> 
    10941103      <td>Boolean</td> 
     
    11041113      <td>No</td> 
    11051114    </tr> 
     1115    <tr> 
     1116      <td>haltonincomplete</td> 
     1117      <td>Boolean</td> 
     1118      <td> Stop the build process if any incomplete tests are encountered. </td> 
     1119      <td>false</td> 
     1120      <td>No</td> 
     1121    </tr> 
     1122    <tr> 
     1123      <td>haltonskipped</td> 
     1124      <td>Boolean</td> 
     1125      <td> Stop the build process if any skipped tests are encountered. </td> 
     1126      <td>false</td> 
     1127      <td>No</td> 
     1128    </tr> 
     1129        <tr> 
     1130      <td>failureproperty</td> 
     1131      <td>String</td> 
     1132      <td>Name of property to set (to true) on failure.</td> 
     1133      <td>n/a</td> 
     1134      <td>No</td> 
     1135        </tr> 
    11061136        <tr> 
    11071137      <td>errorproperty</td> 
     
    11121142        </tr> 
    11131143        <tr> 
    1114       <td>failureproperty</td> 
    1115       <td>String</td> 
    1116       <td>Name of property to set (to true) on failure.</td> 
     1144      <td>incompleteproperty</td> 
     1145      <td>String</td> 
     1146      <td>Name of property to set (to true) on incomplete tests.</td> 
     1147      <td>n/a</td> 
     1148      <td>No</td> 
     1149        </tr> 
     1150        <tr> 
     1151      <td>skippedproperty</td> 
     1152      <td>String</td> 
     1153      <td>Name of property to set (to true) on skipped tests.</td> 
    11171154      <td>n/a</td> 
    11181155      <td>No</td> 
     
    11291166    the other emits plain text. The formatter named brief will only print detailed information for testcases 
    11301167    that failed, while plain gives a little statistics line for all test cases. Custom formatters that 
    1131     implement phing.tasks.ext.PHPUnit2ResultFormatter can be specified.</p> 
     1168    implement phing.tasks.ext.PHPUnitResultFormatter can be specified.</p> 
    11321169    <p>If you use the XML formatter, it may not include the same output that your tests have written as 
    11331170    some characters are illegal in XML documents and will be dropped.</p> 
     
    12221259</ul> 
    12231260<h3>Examples</h3> 
    1224 <pre>&lt;phpunit2&gt; 
     1261<pre>&lt;phpunit&gt; 
    12251262  &lt;formatter todir=&quot;reports&quot; type=&quot;xml&quot;/&gt; 
    12261263  &lt;batchtest&gt; 
     
    12301267    &lt;/fileset&gt; 
    12311268  &lt;/batchtest&gt; 
    1232 &lt;/phpunit2&gt; 
     1269&lt;/phpunit&gt; 
    12331270</pre> 
    12341271<p>Runs all matching testcases in the directory <em>tests</em>, writing 
    12351272XML results to the directory <em>reports</em>.</p> 
    1236 <pre>&lt;phpunit2 haltonfailure=&quot;true&quot; haltonerror=&quot;true&quot;&gt; 
     1273<pre>&lt;phpunit codecoverage=&quot;true&quot; haltonfailure=&quot;true&quot; haltonerror=&quot;true&quot;&gt; 
    12371274  &lt;formatter type=&quot;plain&quot; usefile=&quot;false&quot;/&gt; 
    12381275  &lt;batchtest&gt; 
     
    12411278    &lt;/fileset&gt; 
    12421279  &lt;/batchtest&gt; 
    1243 &lt;/phpunit2&gt; 
     1280&lt;/phpunit&gt; 
    12441281</pre> 
    12451282<p> 
    1246 Runs all matching testcases in the directory <em>tests</em>, writing plain 
     1283Runs all matching testcases in the directory <em>tests</em>, gathers code coverage information, writing plain 
    12471284text results to the console. The build process is aborted if a test 
    12481285fails.</p> 
     
    12511288and counting, and could possibly lead to strange results. Instead, use one of more fileset's to provide a list of testcases to execute.</p> 
    12521289 
    1253 <h2><a name="PHPUnit2Report"></a>PHPUnit2Report</h2> 
    1254 <p>This task transforms PHPUnit2 xml reports to HTML using XSLT.</p> 
     1290<h2><a name="PHPUnitReport"></a>PHPUnitReport</h2> 
     1291<p>This task transforms PHPUnit xml reports to HTML using XSLT.</p> 
     1292<p><b>NB:</b> the identifiers <i>phpunit2report</i> (PHPUnit2Report) and <i>phpunit3report</i> (PHPUnit3Report) have been deprecated, but are still 
     1293available to maintain backwards compatibility.</p> 
    12551294<h3>Attributes</h3> 
    12561295<table> 
     
    13041343</table> 
    13051344<h3>Examples</h3> 
    1306 <pre>&lt;phpunit2report infile=&quot;reports/testsuites.xml&quot; format=&quot;frames&quot; todir=&quot;reports/tests&quot; styledir=&quot;/home/phing/etc&quot;/&gt; 
     1345<pre>&lt;phpunitreport infile=&quot;reports/testsuites.xml&quot; format=&quot;frames&quot; todir=&quot;reports/tests&quot; styledir=&quot;/home/phing/etc&quot;/&gt; 
    13071346</pre> 
    13081347<p>Generates a framed report in the directory <em>reports/tests</em> using 
  • branches/2.3/docs/phing_guide/book/toc/FrameToC.html

    r272 r318  
    134134<li><a href="../chapters/appendixes/AppendixC-OptionalTasks.html#PhpDocumentorTask" target="Content">PhpDocumentorTask</a></li> 
    135135<li><a href="../chapters/appendixes/AppendixC-OptionalTasks.html#PhpLintTask" target="Content">PhpLintTask</a></li> 
    136 <li><a href="../chapters/appendixes/AppendixC-OptionalTasks.html#PHPUnit2Task" target="Content">PHPUnit2Task</a></li> 
    137 <li><a href="../chapters/appendixes/AppendixC-OptionalTasks.html#PHPUnit2Report" target="Content">PHPUnit2Report</a></li> 
     136<li><a href="../chapters/appendixes/AppendixC-OptionalTasks.html#PHPUnitTask" target="Content">PHPUnitTask</a></li> 
     137<li><a href="../chapters/appendixes/AppendixC-OptionalTasks.html#PHPUnitReport" target="Content">PHPUnitReport</a></li> 
    138138<li><a href="../chapters/appendixes/AppendixC-OptionalTasks.html#SvnCheckoutTask" target="Content">SvnCheckoutTask</a></li> 
    139139<li><a href="../chapters/appendixes/AppendixC-OptionalTasks.html#SvnExportTask" target="Content">SvnExportTask</a></li> 
  • branches/2.3/docs/phing_guide/book/toc/ToC.html

    r272 r318  
    119119<li><a href="../chapters/appendixes/AppendixC-OptionalTasks.html#PhpDocumentorTask">PhpDocumentorTask</a></li> 
    120120<li><a href="../chapters/appendixes/AppendixC-OptionalTasks.html#PhpLintTask">PhpLintTask</a></li> 
    121 <li><a href="../chapters/appendixes/AppendixC-OptionalTasks.html#PHPUnit2Task">PHPUnit2Task</a></li> 
    122 <li><a href="../chapters/appendixes/AppendixC-OptionalTasks.html#PHPUnit2Report">PHPUnit2Report</a></li> 
     121<li><a href="../chapters/appendixes/AppendixC-OptionalTasks.html#PHPUnitTask">PHPUnitTask</a></li> 
     122<li><a href="../chapters/appendixes/AppendixC-OptionalTasks.html#PHPUnitReport">PHPUnitReport</a></li> 
    123123<li><a href="../chapters/appendixes/AppendixC-OptionalTasks.html#SvnCheckoutTask">SvnCheckoutTask</a></li> 
    124124<li><a href="../chapters/appendixes/AppendixC-OptionalTasks.html#SvnExportTask">SvnExportTask</a></li>