public function testConstructorWithArray() { $options = array('rootElement' => 'log', 'elementMap' => array('word' => 'message', 'priority' => 'priority')); $event = array('message' => 'tottakai', 'priority' => 4); $expected = '<log><word>tottakai</word><priority>4</priority></log>'; $formatter = new Zend_Log_Formatter_Xml($options); $output = $formatter->format($event); $this->assertContains($expected, $output); $this->assertEquals('UTF-8', $formatter->getEncoding()); }