mirror of
				https://github.com/kevinveenbirkenbach/infinito.git
				synced 2025-10-31 01:09:41 +00:00 
			
		
		
		
	Optimized unit tests and entity implementation
This commit is contained in:
		| @@ -7,6 +7,7 @@ use Doctrine\ORM\EntityManager; | ||||
| use App\Repository\UserRepository; | ||||
| use App\Entity\User; | ||||
| use App\Entity\UserInterface; | ||||
| use App\Entity\Source\Combination\PersonIdentitySourceInterface; | ||||
|  | ||||
| class UserRepositoryTest extends KernelTestCase | ||||
| { | ||||
| @@ -42,6 +43,12 @@ class UserRepositoryTest extends KernelTestCase | ||||
|         $user->setUsername('Karl Marx'); | ||||
|         $user->setEmail('mew21@test.de'); | ||||
|         $user->setPassword('Friedrich ist kein Engel!:)'); | ||||
|         /** | ||||
|          * @var PersonIdentitySourceInterface | ||||
|          */ | ||||
|         $personIdentity = $user->getSource()->getPersonIdentitySource(); | ||||
|         $personIdentity->getFullPersonNameSource()->getFirstNameSource()->setName('Karl'); | ||||
|         $personIdentity->getFullPersonNameSource()->getSurnameSource()->setName('Marx'); | ||||
|         $this->entityManager->persist($user); | ||||
|         $this->entityManager->flush(); | ||||
|         $userId = $user->getId(); | ||||
|   | ||||
		Reference in New Issue
	
	Block a user