Esempio n. 1
0
 protected function _log($message, $params, $level)
 {
     lmb_assert_type($message, 'string');
     lmb_assert_type($params, 'array');
     lmb_assert_type($level, 'integer');
     $this->log->log($message, $level, $params);
 }
Esempio n. 2
0
 function testSetBacktraceDepth()
 {
     $this->log->setBacktraceDepth(LOG_NOTICE, $depth = 0);
     $this->log->log('info', LOG_INFO, array(), new lmbBacktrace());
     $this->assertNotEqual($depth, count($this->_getLastLogEntry()->getBacktrace()->get()));
     $this->log->log('notice', LOG_NOTICE, array(), new lmbBacktrace());
     $this->assertEqual($depth, count($this->_getLastLogEntry()->getBacktrace()->get()));
 }
Esempio n. 3
0
 function testSetBacktraceDepth()
 {
     $this->log->setBacktraceDepth(LOG_ERR, $depth = 0);
     $this->log->log('notice', LOG_NOTICE);
     $this->assertNotEqual($depth, count($this->_getLastLogEntry()->getBacktrace()->get()));
     $this->log->log('error', LOG_ERR);
     $this->assertEqual($depth, count($this->_getLastLogEntry()->getBacktrace()->get()));
 }