PHP Class Kraken\_Unit\Log\LoggerTest

Inheritance: extends Kraken\Test\TUnit
Show file Open project: kraken-php/framework

Public Methods

Method Description
createLogger ( Kraken\Log\Handler\HandlerInterface[] $loggers = [], callable[] $processors = [] ) : Logger
createLoggerMock ( ) : Logger
expect ( string $method, mixed[] $args = null, integer $times = 1 ) : Prophecy\Prophecy\MethodProphecy
prevent ( string $method, mixed[] $args = null ) : Prophecy\Prophecy\MethodProphecy
testApiAlert_CallsMethodOnModel ( )
testApiAlert_ThrowsException_WhenModelThrowsException ( )
testApiConstructor_DoesNotThrowExceptions ( )
testApiCreateWrapper_CreatesWrapper ( )
testApiCritical_CallsMethodOnModel ( )
testApiCritical_ThrowsException_WhenModelThrowsException ( )
testApiDebug_CallsMethodOnModel ( )
testApiDebug_ThrowsException_WhenModelThrowsException ( )
testApiDestructor_DoesNotThrowExceptions ( )
testApiEmergency_CallsMethodOnModel ( )
testApiEmergency_ThrowsException_WhenModelThrowsException ( )
testApiError_CallsMethodOnModel ( )
testApiError_ThrowsException_WhenModelThrowsException ( )
testApiGetHandlers_CallsMethodOnModel ( )
testApiGetName_ReturnsLoggerName ( )
testApiInfo_CallsMethodOnModel ( )
testApiInfo_ThrowsException_WhenModelThrowsException ( )
testApiIsHandling_CallsMethodOnModel ( )
testApiLog_CallsMethodOnModel ( )
testApiLog_ThrowsException_WhenModelThrowsException ( )
testApiNotice_CallsMethodOnModel ( )
testApiNotice_ThrowsException_WhenModelThrowsException ( )
testApiPopHandler_CallsMethodOnModel ( )
testApiPopHandler_ReturnsNull_WhenModelThrowsException ( )
testApiPopProcessor_CallsMethodOnModel ( )
testApiPopProcessor_ReturnsNull_WhenModelThrowsException ( )
testApiPushHandler_CallsMethodOnModel ( )
testApiPushProcessor_CallsMethodOnModel ( )
testApiPushProcessor_ThrowsException_WhenModelThrowsException ( )
testApiWarning_CallsMethodOnModel ( )
testApiWarning_ThrowsException_WhenModelThrowsException ( )

Method Details

createLogger() public method

public createLogger ( Kraken\Log\Handler\HandlerInterface[] $loggers = [], callable[] $processors = [] ) : Logger
$loggers Kraken\Log\Handler\HandlerInterface[]
$processors callable[]
return Kraken\Log\Logger

createLoggerMock() public method

public createLoggerMock ( ) : Logger
return Kraken\Log\Logger

expect() public method

public expect ( string $method, mixed[] $args = null, integer $times = 1 ) : Prophecy\Prophecy\MethodProphecy
$method string
$args mixed[]
$times integer
return Prophecy\Prophecy\MethodProphecy

prevent() public method

public prevent ( string $method, mixed[] $args = null ) : Prophecy\Prophecy\MethodProphecy
$method string
$args mixed[]
return Prophecy\Prophecy\MethodProphecy

testApiAlert_CallsMethodOnModel() public method

testApiAlert_ThrowsException_WhenModelThrowsException() public method

testApiConstructor_DoesNotThrowExceptions() public method

testApiCreateWrapper_CreatesWrapper() public method

testApiCritical_CallsMethodOnModel() public method

testApiCritical_ThrowsException_WhenModelThrowsException() public method

testApiDebug_CallsMethodOnModel() public method

testApiDebug_ThrowsException_WhenModelThrowsException() public method

testApiDestructor_DoesNotThrowExceptions() public method

testApiEmergency_CallsMethodOnModel() public method

testApiEmergency_ThrowsException_WhenModelThrowsException() public method

testApiError_CallsMethodOnModel() public method

testApiError_ThrowsException_WhenModelThrowsException() public method

testApiGetHandlers_CallsMethodOnModel() public method

testApiGetName_ReturnsLoggerName() public method

testApiInfo_CallsMethodOnModel() public method

testApiInfo_ThrowsException_WhenModelThrowsException() public method

testApiIsHandling_CallsMethodOnModel() public method

testApiLog_CallsMethodOnModel() public method

testApiLog_ThrowsException_WhenModelThrowsException() public method

testApiNotice_CallsMethodOnModel() public method

testApiNotice_ThrowsException_WhenModelThrowsException() public method

testApiPopHandler_CallsMethodOnModel() public method

testApiPopHandler_ReturnsNull_WhenModelThrowsException() public method

testApiPopProcessor_CallsMethodOnModel() public method

testApiPopProcessor_ReturnsNull_WhenModelThrowsException() public method

testApiPushHandler_CallsMethodOnModel() public method

testApiPushProcessor_CallsMethodOnModel() public method

testApiPushProcessor_ThrowsException_WhenModelThrowsException() public method

testApiWarning_CallsMethodOnModel() public method

testApiWarning_ThrowsException_WhenModelThrowsException() public method