public function testFactory() { $cfg = array('application' => 'my app', 'facility' => LOG_USER); $writer = SyslogWriter::factory($cfg); $this->assertTrue($writer instanceof SyslogWriter); }
/** * @group ZF-8382 */ public function testWriteWithFormatter() { $event = array( 'message' => 'tottakai', 'priority' => Logger::ERR ); $writer = SyslogWriter::factory(array()); $formatter = new SimpleFormatter('%message% (this is a test)'); $writer->setFormatter($formatter); $writer->write($event); }