/**
  * @test
  */
 public function resultFromSuccessEventContainsNoMessage()
 {
     $entity = new ValidTestEntity();
     $entity->setId(1);
     $metaInformation = new MetaInformation();
     $metaInformation->setClassName('an entity');
     $metaInformation->setEntity($entity);
     $event = new Event(null, $metaInformation, '');
     $factory = new ConsoleResultFactory();
     $result = $factory->fromEvent($event);
     $this->assertEquals(1, $result->getResultId());
     $this->assertEquals('an entity', $result->getEntityClassname());
     $this->assertEquals('', $result->getErrorMessage());
 }
 /**
  * @param Event $event
  */
 public function onSolrSuccess(Event $event)
 {
     $this->commandResult->success($this->resultFactory->fromEvent($event));
 }