30 $redis = $this->getMock(
'Predis\Client');
31 $this->assertInstanceof(
'Monolog\Handler\RedisHandler',
new RedisHandler($redis,
'key'));
36 $redis = $this->getMock(
'Redis');
37 $this->assertInstanceof(
'Monolog\Handler\RedisHandler',
new RedisHandler($redis,
'key'));
42 $redis = $this->getMock(
'Predis\Client',
array(
'rpush'));
45 $redis->expects($this->once())
47 ->with(
'key',
'test');
58 $redis = $this->getMock(
'Redis',
array(
'rpush'));
61 $redis->expects($this->once())
63 ->with(
'key',
'test');
74 $redis = $this->getMock(
'Redis',
array(
'multi',
'rpush',
'ltrim',
'exec'));
77 $redis->expects($this->once())
79 ->will($this->returnSelf());
81 $redis->expects($this->once())
83 ->will($this->returnSelf());
85 $redis->expects($this->once())
87 ->will($this->returnSelf());
89 $redis->expects($this->once())
91 ->will($this->returnSelf());
102 $redis = $this->getMock(
'Predis\Client',
array(
'transaction'));
104 $redisTransaction = $this->getMock(
'Predis\Client',
array(
'rpush',
'ltrim'));
106 $redisTransaction->expects($this->once())
108 ->will($this->returnSelf());
110 $redisTransaction->expects($this->once())
112 ->will($this->returnSelf());
115 $redis->expects($this->once())
116 ->method(
'transaction')
117 ->will($this->returnCallback(
function ($cb) use ($redisTransaction) {
118 $cb($redisTransaction);
const DEBUG
Detailed debug information.
testConstructorShouldWorkWithRedis()
testConstructorShouldThrowExceptionForInvalidRedis()
InvalidArgumentException
getRecord($level=Logger::WARNING, $message='test', $context=array())
Logs to a Redis key using rpush.
testConstructorShouldWorkWithPredis()
const WARNING
Exceptional occurrences that are not errors.
Create styles array
The data for the language used.