PHP Class PHPUnit_Extensions_TestDecorator, qcodo

Use TestDecorator as the base class for defining new test decorators. Test decorator subclasses can be introduced to add behaviour before or after a test is run.
Author: Sebastian Bergmann ([email protected])
Inheritance: extends PHPUnit_Framework_Assert, implements PHPUnit_Framework_Test, implements PHPUnit_Framework_SelfDescribing
Afficher le fichier Open project: qcodo/qcodo Class Usage Examples

Protected Properties

Свойство Type Description
$test object The Test to be decorated.

Méthodes publiques

Méthode Description
__construct ( PHPUnit_Framework_Test $test ) Constructor.
basicRun ( PHPUnit_Framework_TestResult $result ) Runs the test and collects the result in a TestResult.
count ( ) : integer Counts the number of test cases that will be run by this test.
getTest ( ) : PHPUnit_Framework_Test Returns the test to be run.
run ( PHPUnit_Framework_TestResult $result = NULL ) : PHPUnit_Framework_TestResult Runs the decorated test and collects the result in a TestResult.
toString ( ) : string Returns a string representation of the test.

Méthodes protégées

Méthode Description
createResult ( ) : PHPUnit_Framework_TestResult Creates a default TestResult object.

Method Details

__construct() public méthode

Constructor.
public __construct ( PHPUnit_Framework_Test $test )
$test PHPUnit_Framework_Test

basicRun() public méthode

Runs the test and collects the result in a TestResult.
public basicRun ( PHPUnit_Framework_TestResult $result )
$result PHPUnit_Framework_TestResult

count() public méthode

Counts the number of test cases that will be run by this test.
public count ( ) : integer
Résultat integer

createResult() protected méthode

Creates a default TestResult object.
protected createResult ( ) : PHPUnit_Framework_TestResult
Résultat PHPUnit_Framework_TestResult

getTest() public méthode

Returns the test to be run.
public getTest ( ) : PHPUnit_Framework_Test
Résultat PHPUnit_Framework_Test

run() public méthode

Runs the decorated test and collects the result in a TestResult.
public run ( PHPUnit_Framework_TestResult $result = NULL ) : PHPUnit_Framework_TestResult
$result PHPUnit_Framework_TestResult
Résultat PHPUnit_Framework_TestResult

toString() public méthode

Returns a string representation of the test.
public toString ( ) : string
Résultat string

Property Details

$test protected_oe property

The Test to be decorated.
protected object $test
Résultat object