63 {
65 $this->res = fopen('php://memory', 'a');
66 $this->handler = $this->getMock(
67 '\Monolog\Handler\FlowdockHandler',
68 array('fsockopen', 'streamSetTimeout', 'closeSocket'),
69 $constructorArgs
70 );
71
72 $reflectionProperty = new \ReflectionProperty('\Monolog\Handler\SocketHandler', 'connectionString');
73 $reflectionProperty->setAccessible(true);
74 $reflectionProperty->setValue($this->handler, 'localhost:1234');
75
76 $this->handler->expects($this->any())
77 ->method('fsockopen')
78 ->will($this->returnValue($this->res));
79 $this->handler->expects($this->any())
80 ->method('streamSetTimeout')
81 ->will($this->returnValue(true));
82 $this->handler->expects($this->any())
83 ->method('closeSocket')
84 ->will($this->returnValue(true));
85
86 $this->handler->setFormatter(new FlowdockFormatter('test_source', 'source@test.com'));
87 }
const DEBUG
Detailed debug information.