25 $handler = $this->getMockForAbstractClass(
'Monolog\Handler\AbstractProcessingHandler', array(
Logger::WARNING,
true));
26 $this->assertFalse($handler->handle($this->getRecord(
Logger::DEBUG)));
34 $handler = $this->getMockForAbstractClass(
'Monolog\Handler\AbstractProcessingHandler', array(
Logger::DEBUG,
true));
35 $this->assertFalse($handler->handle($this->getRecord()));
43 $handler = $this->getMockForAbstractClass(
'Monolog\Handler\AbstractProcessingHandler', array(
Logger::DEBUG,
false));
44 $this->assertTrue($handler->handle($this->getRecord()));
52 $handler = $this->getMockForAbstractClass(
'Monolog\Handler\AbstractProcessingHandler', array(
Logger::WARNING,
false));
53 $this->assertTrue($handler->handle($this->getRecord()));
54 $this->assertFalse($handler->handle($this->getRecord(
Logger::DEBUG)));
62 $handler = $this->getMockForAbstractClass(
'Monolog\Handler\AbstractProcessingHandler');
65 'REQUEST_METHOD' =>
'',
70 $handledRecord =
null;
71 $handler->expects($this->once())
73 ->will($this->returnCallback(
function ($record) use (&$handledRecord) {
74 $handledRecord = $record;
78 $this->assertEquals(6, count($handledRecord[
'extra']));
testHandleNotBubbling()
@covers Monolog\Handler\AbstractProcessingHandler::handle
testHandleIsFalseWhenNotHandled()
@covers Monolog\Handler\AbstractProcessingHandler::handle
testProcessRecord()
@covers Monolog\Handler\AbstractProcessingHandler::processRecord
testHandleBubbling()
@covers Monolog\Handler\AbstractProcessingHandler::handle
testHandleLowerLevelMessage()
@covers Monolog\Handler\AbstractProcessingHandler::handle
const WARNING
Exceptional occurrences that are not errors.
const DEBUG
Detailed debug information.
Injects url/method and remote IP of the current web request in all records.
getRecord($level=Logger::WARNING, $message='test', $context=array())