PHP 클래스 Mutagenesis\Runner\RunnerAbstract

파일 보기 프로젝트 열기: padraic/mutagenesis 1 사용 예제들

보호된 프로퍼티들

프로퍼티 타입 설명
$_adapter Mutagenesis\Adapter\AdapterAbstract Instance of \Mutagenesis\Adapter\AdapterAbstract linking Mutagenesis to to an underlying test framework to execute tests and parse the test results
$_adapterConstraint string Adapter constraint. Used in initial run to analyse what tests/cases/suites are to be executed. For example, calling "phpunit MyTests MyTests.php" sets a constraint of "MyTests MyTests.php". Used to narrow the focus of the current mutation testing run if needed (e.g. spreading testing over time)
$_adapterName string Name of the test adapter, e.g. phpunit, to utilise
$_adapterOptions string String of adapter options appended to any call to the current adapter's testing utility command (e.g. passing 'AllTests.php' to phpunit)
$_baseDirectory string Path to the base directory of the project being mutated
$_bootstrap string Test framework bootstrap
$_cacheDirectory string Path to a cache directory used by library to store working files such as PHPUnit logs needed to analyse test case execution times.
$_detailCaptures boolean Flag to add detailed reports (including test results) about the mutations which caused test failures (i.e. captured)
$_generator Mutagenesis\Generator Instance of \Mutagenesis\Generator used to generate mutations from the underlying source code
$_mutables array Stored mutables each containing relevant mutations for the source code being tested
$_options array Generic options, possibly of future use to other test frameworks
$_renderer Mutagenesis\Renderer\Text Instance of a suitable renderer used to format results into output
$_rendererName string Name of the renderer, e.g. text, to utilise
$_runkit Mutagenesis\Utility\Runkit Instance of \Mutagenesis\Runkit used to apply and reverse mutations on loaded source code within the same process dynamically
$_sourceDirectory string Path to the source directory of the project being mutated
$_testDirectory string Path to the tests directory of the project being mutated
$_timeout integer Timeout in seconds allowed per test execution.

공개 메소드들

메소드 설명
execute ( ) : void Execute the runner
getAdapter ( ) : AdapterAbstract Get a test framework adapter. Creates a new one based on the configured adapter name passed on the CLI if not already set.
getAdapterConstraint ( ) : string Get name of the test adapter to use
getAdapterName ( ) : string Get name of the test adapter to use
getAdapterOptions ( ) : string Get a space delimited string of testing tool options
getBaseDirectory ( ) : string Get the base directory of the project being mutated
getBootstrap ( ) : string Get a bootstrap file included before tests run
getCacheDirectory ( ) : string Get the cache directory of the project being mutated
getDetailCaptures ( ) : boolean Get flag to add detailed reports (including test results) about the mutations which caused test failures (i.e. captured)
getGenerator ( ) : Generator Get a specific Generator of mutations.
getMutables ( ) : array Generate Mutants!
getOptions ( ) : array Compile all necessary options for the test framework adapter
getRenderer ( ) : Mutagenesis\Renderer\RendererInterface Get a result renderer. Creates a new one based on the configured renderer name passed on the CLI if not already set.
getRendererName ( ) : string Get name of the renderer to use
getRunkit ( ) : Mutagenesis\Runkit Creates and returns a new instance of \Mutagenesis\Runkit if not previously loaded
getSourceDirectory ( ) : string Get the source directory of the project being mutated
getTestDirectory ( ) : string Get the test directory of the project being mutated
getTimeout ( ) : null | integer Get timeout in seconds for each test run
setAdapter ( AdapterAbstract $adapter ) Set a test framework adapter.
setAdapterConstraint ( $constraint ) Set name of the test adapter to use
setAdapterName ( string $adapter ) Set name of the test adapter to use
setAdapterOption ( string $optionString ) Options to pass to adapter's underlying command
setAdapterOptions ( array | string $options ) : self Set many options for adapter's underlying cli command
setBaseDirectory ( string $dir ) Set the base directory of the project being mutated
setBootstrap ( string $file ) Set a bootstrap file included before tests run (e.g. setup autoloading)
setCacheDirectory ( string $dir ) Set the cache directory of the project being mutated
setDetailCaptures ( boolean $bool ) Set flag to add detailed reports (including test results) about the mutations which caused test failures (i.e. captured)
setGenerator ( Generator $generator ) Set a specific Generator of mutations (stuck with a subclass).
setOption ( string $name, mixed $value ) Set a generic option
setOptions ( array $options ) Set generic options
setRenderer ( Mutagenesis\Renderer\RendererInterface $renderer ) Set a test framework adapter.
setRendererName ( string $rname ) Set name of the renderer to use
setRunkit ( Runkit $runkit ) Set a custom runkit instance.
setSourceDirectory ( string $dir ) Set the source directory of the project being mutated
setTestDirectory ( string $dir ) Set the test directory of the project being mutated
setTimeout ( integer $timeout ) Set timeout in seconds for each test run

메소드 상세

execute() 추상적인 공개 메소드

Execute the runner
abstract public execute ( ) : void
리턴 void

getAdapter() 공개 메소드

Get a test framework adapter. Creates a new one based on the configured adapter name passed on the CLI if not already set.
public getAdapter ( ) : AdapterAbstract
리턴 Mutagenesis\Adapter\AdapterAbstract

getAdapterConstraint() 공개 메소드

Get name of the test adapter to use
public getAdapterConstraint ( ) : string
리턴 string

getAdapterName() 공개 메소드

Get name of the test adapter to use
public getAdapterName ( ) : string
리턴 string

getAdapterOptions() 공개 메소드

Get a space delimited string of testing tool options
public getAdapterOptions ( ) : string
리턴 string

getBaseDirectory() 공개 메소드

Get the base directory of the project being mutated
public getBaseDirectory ( ) : string
리턴 string

getBootstrap() 공개 메소드

Get a bootstrap file included before tests run
public getBootstrap ( ) : string
리턴 string

getCacheDirectory() 공개 메소드

Get the cache directory of the project being mutated
public getCacheDirectory ( ) : string
리턴 string

getDetailCaptures() 공개 메소드

Get flag to add detailed reports (including test results) about the mutations which caused test failures (i.e. captured)
public getDetailCaptures ( ) : boolean
리턴 boolean

getGenerator() 공개 메소드

Get a specific Generator of mutations.
public getGenerator ( ) : Generator
리턴 Mutagenesis\Generator

getMutables() 공개 메소드

Generate Mutants!
public getMutables ( ) : array
리턴 array

getOptions() 공개 메소드

Compile all necessary options for the test framework adapter
public getOptions ( ) : array
리턴 array

getRenderer() 공개 메소드

Get a result renderer. Creates a new one based on the configured renderer name passed on the CLI if not already set.
public getRenderer ( ) : Mutagenesis\Renderer\RendererInterface
리턴 Mutagenesis\Renderer\RendererInterface

getRendererName() 공개 메소드

Get name of the renderer to use
public getRendererName ( ) : string
리턴 string

getRunkit() 공개 메소드

Creates and returns a new instance of \Mutagenesis\Runkit if not previously loaded
public getRunkit ( ) : Mutagenesis\Runkit
리턴 Mutagenesis\Runkit

getSourceDirectory() 공개 메소드

Get the source directory of the project being mutated
public getSourceDirectory ( ) : string
리턴 string

getTestDirectory() 공개 메소드

Get the test directory of the project being mutated
public getTestDirectory ( ) : string
리턴 string

getTimeout() 공개 메소드

Get timeout in seconds for each test run
public getTimeout ( ) : null | integer
리턴 null | integer

setAdapter() 공개 메소드

Set a test framework adapter.
public setAdapter ( AdapterAbstract $adapter )
$adapter Mutagenesis\Adapter\AdapterAbstract

setAdapterConstraint() 공개 메소드

Set name of the test adapter to use
public setAdapterConstraint ( $constraint )

setAdapterName() 공개 메소드

Set name of the test adapter to use
public setAdapterName ( string $adapter )
$adapter string

setAdapterOption() 공개 메소드

Options to pass to adapter's underlying command
public setAdapterOption ( string $optionString )
$optionString string

setAdapterOptions() 공개 메소드

Set many options for adapter's underlying cli command
public setAdapterOptions ( array | string $options ) : self
$options array | string Array or serialized array of options
리턴 self

setBaseDirectory() 공개 메소드

Set the base directory of the project being mutated
public setBaseDirectory ( string $dir )
$dir string

setBootstrap() 공개 메소드

Set a bootstrap file included before tests run (e.g. setup autoloading)
public setBootstrap ( string $file )
$file string

setCacheDirectory() 공개 메소드

Set the cache directory of the project being mutated
public setCacheDirectory ( string $dir )
$dir string

setDetailCaptures() 공개 메소드

Set flag to add detailed reports (including test results) about the mutations which caused test failures (i.e. captured)
public setDetailCaptures ( boolean $bool )
$bool boolean

setGenerator() 공개 메소드

TODO Add interface
public setGenerator ( Generator $generator )
$generator Mutagenesis\Generator

setOption() 공개 메소드

Set a generic option
public setOption ( string $name, mixed $value )
$name string
$value mixed

setOptions() 공개 메소드

Set generic options
public setOptions ( array $options )
$options array

setRenderer() 공개 메소드

Set a test framework adapter.
public setRenderer ( Mutagenesis\Renderer\RendererInterface $renderer )
$renderer Mutagenesis\Renderer\RendererInterface

setRendererName() 공개 메소드

Set name of the renderer to use
public setRendererName ( string $rname )
$rname string

setRunkit() 공개 메소드

Set a custom runkit instance.
public setRunkit ( Runkit $runkit )
$runkit Mutagenesis\Utility\Runkit

setSourceDirectory() 공개 메소드

Set the source directory of the project being mutated
public setSourceDirectory ( string $dir )
$dir string

setTestDirectory() 공개 메소드

Set the test directory of the project being mutated
public setTestDirectory ( string $dir )
$dir string

setTimeout() 공개 메소드

Set timeout in seconds for each test run
public setTimeout ( integer $timeout )
$timeout integer

프로퍼티 상세

$_adapter 보호되어 있는 프로퍼티

Instance of \Mutagenesis\Adapter\AdapterAbstract linking Mutagenesis to to an underlying test framework to execute tests and parse the test results
protected AdapterAbstract,Mutagenesis\Adapter $_adapter
리턴 Mutagenesis\Adapter\AdapterAbstract

$_adapterConstraint 보호되어 있는 프로퍼티

Adapter constraint. Used in initial run to analyse what tests/cases/suites are to be executed. For example, calling "phpunit MyTests MyTests.php" sets a constraint of "MyTests MyTests.php". Used to narrow the focus of the current mutation testing run if needed (e.g. spreading testing over time)
protected string $_adapterConstraint
리턴 string

$_adapterName 보호되어 있는 프로퍼티

Name of the test adapter, e.g. phpunit, to utilise
protected string $_adapterName
리턴 string

$_adapterOptions 보호되어 있는 프로퍼티

String of adapter options appended to any call to the current adapter's testing utility command (e.g. passing 'AllTests.php' to phpunit)
protected string $_adapterOptions
리턴 string

$_baseDirectory 보호되어 있는 프로퍼티

Path to the base directory of the project being mutated
protected string $_baseDirectory
리턴 string

$_bootstrap 보호되어 있는 프로퍼티

Test framework bootstrap
protected string $_bootstrap
리턴 string

$_cacheDirectory 보호되어 있는 프로퍼티

Path to a cache directory used by library to store working files such as PHPUnit logs needed to analyse test case execution times.
protected string $_cacheDirectory
리턴 string

$_detailCaptures 보호되어 있는 프로퍼티

Flag to add detailed reports (including test results) about the mutations which caused test failures (i.e. captured)
protected bool $_detailCaptures
리턴 boolean

$_generator 보호되어 있는 프로퍼티

Instance of \Mutagenesis\Generator used to generate mutations from the underlying source code
protected Generator,Mutagenesis $_generator
리턴 Mutagenesis\Generator

$_mutables 보호되어 있는 프로퍼티

Stored mutables each containing relevant mutations for the source code being tested
protected array $_mutables
리턴 array

$_options 보호되어 있는 프로퍼티

Generic options, possibly of future use to other test frameworks
protected array $_options
리턴 array

$_renderer 보호되어 있는 프로퍼티

Instance of a suitable renderer used to format results into output
protected Text,Mutagenesis\Renderer $_renderer
리턴 Mutagenesis\Renderer\Text

$_rendererName 보호되어 있는 프로퍼티

Name of the renderer, e.g. text, to utilise
protected string $_rendererName
리턴 string

$_runkit 보호되어 있는 프로퍼티

Instance of \Mutagenesis\Runkit used to apply and reverse mutations on loaded source code within the same process dynamically
protected Runkit,Mutagenesis\Utility $_runkit
리턴 Mutagenesis\Utility\Runkit

$_sourceDirectory 보호되어 있는 프로퍼티

Path to the source directory of the project being mutated
protected string $_sourceDirectory
리턴 string

$_testDirectory 보호되어 있는 프로퍼티

Path to the tests directory of the project being mutated
protected string $_testDirectory
리턴 string

$_timeout 보호되어 있는 프로퍼티

Timeout in seconds allowed per test execution.
protected int $_timeout
리턴 integer