Lggr
Public Member Functions | Static Public Member Functions | Public Attributes | Protected Member Functions | Protected Attributes | Static Protected Attributes | List of all members
PHPUnit\TextUI\TestRunner Class Reference
Inheritance diagram for PHPUnit\TextUI\TestRunner:
Inheritance graph
[legend]
Collaboration diagram for PHPUnit\TextUI\TestRunner:
Collaboration graph
[legend]

Public Member Functions

 __construct (TestSuiteLoader $loader=null, CodeCoverageFilter $filter=null)
 
 doRun (Test $suite, array $arguments=[], $exit=true)
 
 setPrinter (ResultPrinter $resultPrinter)
 
 getLoader ()
 
- Public Member Functions inherited from PHPUnit\Runner\BaseTestRunner
 getTest ($suiteClassName, $suiteClassFile='', $suffixes='')
 

Static Public Member Functions

static run ($test, array $arguments=[], $exit=true)
 

Public Attributes

const SUCCESS_EXIT = 0
 
const FAILURE_EXIT = 1
 
const EXCEPTION_EXIT = 2
 
- Public Attributes inherited from PHPUnit\Runner\BaseTestRunner
const STATUS_PASSED = 0
 
const STATUS_SKIPPED = 1
 
const STATUS_INCOMPLETE = 2
 
const STATUS_FAILURE = 3
 
const STATUS_ERROR = 4
 
const STATUS_RISKY = 5
 
const STATUS_WARNING = 6
 
const SUITE_METHODNAME = 'suite'
 

Protected Member Functions

 createTestResult ()
 
 runFailed ($message)
 
 write ($buffer)
 
 handleConfiguration (array &$arguments)
 
- Protected Member Functions inherited from PHPUnit\Runner\BaseTestRunner
 loadSuiteClass ($suiteClassName, $suiteClassFile='')
 
 clearStatus ()
 

Protected Attributes

 $codeCoverageFilter
 
 $loader
 
 $printer
 

Static Protected Attributes

static $versionStringPrinted = false
 

Detailed Description

A TestRunner for the Command Line Interface (CLI) PHP SAPI Module.

Constructor & Destructor Documentation

◆ __construct()

PHPUnit\TextUI\TestRunner::__construct ( TestSuiteLoader  $loader = null,
CodeCoverageFilter  $filter = null 
)
Parameters
TestSuiteLoader$loader
CodeCoverageFilter$filter

Member Function Documentation

◆ createTestResult()

PHPUnit\TextUI\TestRunner::createTestResult ( )
protected
Returns
TestResult

◆ doRun()

PHPUnit\TextUI\TestRunner::doRun ( Test  $suite,
array  $arguments = [],
  $exit = true 
)
Parameters
Test$suite
array$arguments
bool$exit
Returns
TestResult

◆ getLoader()

PHPUnit\TextUI\TestRunner::getLoader ( )

Returns the loader to be used.

Returns
TestSuiteLoader

Reimplemented from PHPUnit\Runner\BaseTestRunner.

◆ handleConfiguration()

PHPUnit\TextUI\TestRunner::handleConfiguration ( array &  $arguments)
protected
Parameters
array$arguments

◆ run()

static PHPUnit\TextUI\TestRunner::run (   $test,
array  $arguments = [],
  $exit = true 
)
static
Parameters
Test | ReflectionClass$test
array$arguments
bool$exit
Returns
TestResult
Exceptions
Exception

◆ runFailed()

PHPUnit\TextUI\TestRunner::runFailed (   $message)
protected

Override to define how to handle a failed loading of a test suite.

Parameters
string$message

Reimplemented from PHPUnit\Runner\BaseTestRunner.

◆ setPrinter()

PHPUnit\TextUI\TestRunner::setPrinter ( ResultPrinter  $resultPrinter)
Parameters
ResultPrinter$resultPrinter

◆ write()

PHPUnit\TextUI\TestRunner::write (   $buffer)
protected
Parameters
string$buffer

The documentation for this class was generated from the following file: