unregisterReconstitutedEntity() public method

Unregisters data for a reconstituted object
public unregisterReconstitutedEntity ( object $entity ) : void
$entity object
return void
 /**
  * @test
  */
 public function unregisterReconstitutedEntityRemovesObjectFromSession()
 {
     $someObject = new \ArrayObject([]);
     $session = new Persistence\Generic\Session();
     $session->registerObject($someObject, 'fakeUuid');
     $session->registerReconstitutedEntity($someObject, ['identifier' => 'fakeUuid']);
     $session->unregisterReconstitutedEntity($someObject);
     $ReconstitutedEntities = $session->getReconstitutedEntities();
     $this->assertFalse($ReconstitutedEntities->contains($someObject));
 }
 /**
  * Iterate over deleted entities and process them
  *
  * @return void
  */
 protected function processDeletedObjects()
 {
     foreach ($this->deletedEntities as $entity) {
         if ($this->persistenceSession->hasObject($entity)) {
             $this->removeEntity($entity);
             $this->persistenceSession->unregisterReconstitutedEntity($entity);
             $this->persistenceSession->unregisterObject($entity);
         }
     }
     $this->deletedEntities = new \SplObjectStorage();
 }