32 $this->assertFalse(
$test->hasDebugRecords());
33 $this->assertFalse(
$test->hasInfoRecords());
36 $this->assertTrue(
$test->hasInfoRecords());
37 $this->assertTrue(count(
$test->getRecords()) === 3);
50 $this->assertTrue(
$test->hasWarningRecords());
51 $this->assertTrue(
$test->hasDebugRecords());
67 $this->assertTrue(
$test->hasWarningRecords());
68 $this->assertTrue(
$test->hasDebugRecords());
69 $this->assertFalse(
$test->hasInfoRecords());
83 $this->assertTrue(
$test->hasWarningRecords());
84 $this->assertTrue(
$test->hasDebugRecords());
85 $this->assertFalse(
$test->hasInfoRecords());
99 $this->assertTrue(
$test->hasWarningRecords());
100 $this->assertTrue(
$test->hasInfoRecords());
101 $this->assertFalse(
$test->hasDebugRecords());
115 $this->assertFalse(
$test->hasDebugRecords());
116 $this->assertFalse(
$test->hasInfoRecords());
118 $this->assertTrue(
$test->hasInfoRecords());
119 $this->assertTrue(count(
$test->getRecords()) === 3);
141 $this->assertTrue($handler->isHandling($this->getRecord(
Logger::DEBUG)));
154 $this->assertFalse(
$test->hasDebugRecords());
156 $this->assertTrue(
$test->hasDebugRecords());
157 $this->assertTrue(
$test->hasWarningRecords());
170 $this->assertFalse(
$test->hasDebugRecords());
172 $this->assertTrue(
$test->hasDebugRecords());
173 $this->assertTrue(
$test->hasWarningRecords());
185 $this->assertFalse(
$test->hasWarningRecords());
187 $record[
'channel'] =
'othertest';
188 $handler->handle($record);
189 $this->assertTrue(
$test->hasDebugRecords());
190 $this->assertTrue(
$test->hasWarningRecords());
202 $this->assertFalse(
$test->hasWarningRecords());
204 $record[
'channel'] =
'othertest';
205 $handler->handle($record);
206 $this->assertTrue(
$test->hasDebugRecords());
207 $this->assertTrue(
$test->hasWarningRecords());
217 $handler->pushProcessor(
function ($record) {
218 $record[
'extra'][
'foo'] =
true;
223 $this->assertTrue(
$test->hasWarningRecords());
225 $this->assertTrue(
$records[0][
'extra'][
'foo']);
238 $this->assertFalse(
$test->hasDebugRecords());
239 $this->assertTrue(
$test->hasInfoRecords());
252 $this->assertFalse(
$test->hasDebugRecords());
253 $this->assertTrue(
$test->hasInfoRecords());
testErrorLevelActivationStrategy()
@covers Monolog\Handler\FingersCrossedHandler::__construct @covers Monolog\Handler\FingersCrossed\Err...
testHandleBuffers()
@covers Monolog\Handler\FingersCrossedHandler::__construct @covers Monolog\Handler\FingersCrossedHand...
testPassthruOnClose()
@covers Monolog\Handler\FingersCrossedHandler::close
testHandleRestartBufferingAfterBeingTriggeredWhenStopBufferingIsDisabled()
@covers Monolog\Handler\FingersCrossedHandler::handle
testHandleStopsBufferingAfterTrigger()
@covers Monolog\Handler\FingersCrossedHandler::handle
testHandleWithBadCallbackThrowsException()
@covers Monolog\Handler\FingersCrossedHandler::handle @expectedException RuntimeException
testHandleRestartBufferingAfterReset()
@covers Monolog\Handler\FingersCrossedHandler::handle @covers Monolog\Handler\FingersCrossedHandler::...
testHandleBufferLimit()
@covers Monolog\Handler\FingersCrossedHandler::handle
testChannelLevelActivationStrategy()
@covers Monolog\Handler\FingersCrossed\ChannelLevelActivationStrategy::__construct @covers Monolog\Ha...
testChannelLevelActivationStrategyWithPsrLevels()
@covers Monolog\Handler\FingersCrossed\ChannelLevelActivationStrategy::__construct @covers Monolog\Ha...
testIsHandlingAlways()
@covers Monolog\Handler\FingersCrossedHandler::isHandling
testHandleWithCallback()
@covers Monolog\Handler\FingersCrossedHandler::handle
testPsrLevelPassthruOnClose()
@covers Monolog\Handler\FingersCrossedHandler::close
testErrorLevelActivationStrategyWithPsrLevel()
@covers Monolog\Handler\FingersCrossedHandler::__construct @covers Monolog\Handler\FingersCrossed\Err...
testHandleUsesProcessors()
@covers Monolog\Handler\FingersCrossedHandler::handle
Buffers all records until a certain level is reached.
handle(array $record)
{Handles a record.All records may be passed to this method, and the handler should discard those that...
Channel and Error level based monolog activation strategy.
Error level based activation strategy.
Used for testing purposes.
const ERROR
Runtime errors.
const WARNING
Exceptional occurrences that are not errors.
const INFO
Interesting events.
const DEBUG
Detailed debug information.
getRecord($level=Logger::WARNING, $message='test', $context=array())