CakeTestRunner (class)

Class CakeTestRunner

A custom test runner for CakePHP's use of PHPUnit.

PHPUnit_TextUI_TestRunner
Extended by CakeTestRunner
Package: Cake\TestSuite
Copyright: Copyright (c) Cake Software Foundation, Inc. (http://cakefoundation.org)
License: MIT License
Located at Cake/TestSuite/CakeTestRunner.php

Method Detail

__constructsource public

__construct( mixed $loader , array $params )

Lets us pass in some options needed for CakePHP's webrunner.

Parameters

mixed $loader
The test suite loader
array $params
list of options to be used for this run

_getFixtureManagersource protected

_getFixtureManager( array $arguments )

Get the fixture manager class specified or use the default one.

Parameters

array $arguments
The CLI arguments.

Returns

mixed
instance of a fixture manager.

Throws

RuntimeException
When fixture manager class cannot be loaded.

createTestResultsource protected

createTestResult( )

Create the test result and splice on our code coverage reports.

Returns

PHPUnit_Framework_TestResult
PHPUnit_Framework_TestResult

doRunsource public

doRun( PHPUnit_Framework_Test $suite , array $arguments array() )

Actually run a suite of tests. Cake initializes fixtures here using the chosen fixture manager

Parameters

PHPUnit_Framework_Test $suite
The test suite to run
array $arguments optional array()
The CLI arguments

© 2005–2016 The Cake Software Foundation, Inc.
Licensed under the MIT License.
CakePHP is a registered trademark of Cake Software Foundation, Inc.
We are not endorsed by or affiliated with CakePHP.
http://api.cakephp.org/2.7/class-CakeTestRunner.html

在线笔记
App下载
App下载

扫描二维码

下载编程狮App

公众号
微信公众号

编程狮公众号

意见反馈
返回顶部