/**
  * 测试AuthLoggerListener::onFailure()
  */
 public function testOnFailure()
 {
     $e = new Event();
     $e->setFailure(new Failure('Test', array('result' => '123456')));
     $this->events->trigger(Event::EVENT_FAILURE, $e);
     $this->assertStringMatchesFormat('%s WARN (4): Test {"result":"123456"}%w', file_get_contents($this->destfile));
 }