PHP Class Autarky\Testing\TestCase

Inheritance: extends PHPUnit_Framework_TestCas\PHPUnit_Framework_TestCase
Datei anzeigen Open project: autarky/framework Class Usage Examples

Protected Properties

Property Type Description
$app Autarky\Application The application instance.

Public Methods

Method Description
setUp ( )
tearDown ( )

Protected Methods

Method Description
createApplication ( ) : Application Create and return the application instance.
enableExceptionHandling ( ) : void Enable exception handling in the application being tested.

Method Details

createApplication() abstract protected method

Usually this will simply be a require of your app/start.php file. Make sure that this file does return $app; at the end.
abstract protected createApplication ( ) : Application
return Autarky\Application

enableExceptionHandling() protected method

By default, uncaught exceptions in the application will simply be thrown again, meaning you have to call setExpectedException or similar if an exception is expected behaviour. If instead you want the application error handler to do its job and return a response, call this method.
protected enableExceptionHandling ( ) : void
return void

setUp() public method

public setUp ( )

tearDown() public method

public tearDown ( )

Property Details

$app protected_oe property

The application instance.
protected Application,Autarky $app
return Autarky\Application