Exemplo n.º 1
0
 /**
  * {@inheritdoc}
  */
 public function remove(ResourceInterface $resource)
 {
     if (null !== $this->find($resource->getId())) {
         $this->dm->remove($resource);
         $this->dm->flush();
     }
 }
 function it_transforms_resource_in_identifier(RepositoryInterface $repository, ResourceInterface $resource)
 {
     $repository->getClassName()->willReturn(ResourceInterface::class);
     $resource->getId()->willReturn(6);
     $this->transform($resource)->shouldReturn(6);
 }