classes/phing/tasks/ext/phpunit/PHPUnitTask.php

\PHPUnitTask

Runs PHPUnit tests.

Use {@link Project#createTask} to register a new Task.

Extends from
\Task
see
\BatchTest
author
Michiel Rook
copyright
2001,2002 THYRELL. All rights reserved
package
phing.tasks.ext.phpunit
since
2.1.0
version
$Id: PHPUnitTask.php 1229 2011-07-25 19:54:19Z mrook $

Properties

Propertyprivate  $batchtests= 'array'
Default valuearrayDetails
Type
Propertyprivate  $bootstrap= ''
Details
Type
Propertyprivate  $codecoverage= 'false'
Default valuefalseDetails
Type
Propertyprivate  $errorproperty= ''
Details
Type
Propertyprivate  $excludeGroups= 'array'
Default valuearrayDetails
Type
Propertyprivate  $failureproperty= ''
Details
Type
Propertyprivate  $formatters= 'array'
Default valuearrayDetails
Type
Propertyprivate  $groups= 'array'
Default valuearrayDetails
Type
Propertyprivate  $haltonerror= 'false'
Default valuefalseDetails
Type
Propertyprivate  $haltonfailure= 'false'
Default valuefalseDetails
Type
Propertyprivate  $haltonincomplete= 'false'
Default valuefalseDetails
Type
Propertyprivate  $haltonskipped= 'false'
Default valuefalseDetails
Type
Propertyprivate  $incompleteproperty= ''
Details
Type
Propertyprivate  $printsummary= 'false'
Default valuefalseDetails
Type
Propertyprivate  $processIsolation= 'false'
Default valuefalseDetails
Type
Propertyprivate  $skippedproperty= ''
Details
Type
Propertyprivate  $testfailed= 'false'
Default valuefalseDetails
Type
Propertyprivate  $testfailuremessage= ''
Details
Type
Propertyprivate  $usecustomerrorhandler= 'true'
Default valuetrueDetails
Type

Methods

methodpublic  addFormatter( \FormatterElement $fe ) :
Add a new formatter to all tests of this task.
Parameters
Name Type Description
$fe \FormatterElement formatter element
methodpublic  createBatchTest( ) : \BatchTest
Adds a set of tests based on pattern matching.
Returns
Type Description
\BatchTest
methodprotected  execute(  $suite ) :
Parameters
Name Type Description
$suite
Details
throws
methodprotected  getDefaultOutput( ) :
methodpublic  getHaltonfailure( ) :
methodpublic  getHaltonincomplete( ) :
methodpublic  getHaltonskipped( ) :
methodpublic  init( ) :
Initialize Task.

This method includes any necessary PHPUnit libraries and triggers appropriate error if they cannot be found. This is not done in header because we may want this class to be loaded w/o triggering an error.

methodpublic  main( ) :
The main entry point
Details
throws
methodpublic  setBootstrap( string $bootstrap ) :
Sets the name of a bootstrap file that is run before executing the tests
Parameters
Name Type Description
$bootstrap string the name of the bootstrap file
methodpublic  setCodecoverage(  $codecoverage ) :
Parameters
Name Type Description
$codecoverage
methodpublic  setErrorproperty(  $value ) :
Parameters
Name Type Description
$value
methodpublic  setExcludeGroups(  $excludeGroups ) :
Parameters
Name Type Description
$excludeGroups
methodpublic  setFailureproperty(  $value ) :
Parameters
Name Type Description
$value
methodpublic  setGroups(  $groups ) :
Parameters
Name Type Description
$groups
methodpublic  setHaltonerror(  $value ) :
Parameters
Name Type Description
$value
methodpublic  setHaltonfailure(  $value ) :
Parameters
Name Type Description
$value
methodpublic  setHaltonincomplete(  $value ) :
Parameters
Name Type Description
$value
methodpublic  setHaltonskipped(  $value ) :
Parameters
Name Type Description
$value
methodpublic  setIncompleteproperty(  $value ) :
Parameters
Name Type Description
$value
methodpublic  setPrintsummary(  $printsummary ) :
Parameters
Name Type Description
$printsummary
methodpublic  setProcessIsolation(  $processIsolation ) :
Parameters
Name Type Description
$processIsolation
methodpublic  setSkippedproperty(  $value ) :
Parameters
Name Type Description
$value
methodpublic  setUseCustomErrorHandler(  $usecustomerrorhandler ) :
Parameters
Name Type Description
$usecustomerrorhandler
Documentation was generated by DocBlox 0.13.1.