mirror of
https://gitlab.com/Chill-Projet/chill-bundles.git
synced 2025-10-04 12:29:43 +00:00
Attempt fix ActivityVoterTest.php
This commit is contained in:
@@ -12,6 +12,8 @@ declare(strict_types=1);
|
||||
namespace Chill\PersonBundle\Test;
|
||||
|
||||
use Chill\MainBundle\Entity\Center;
|
||||
use Chill\MainBundle\Entity\Gender;
|
||||
use Chill\MainBundle\Entity\GenderEnum;
|
||||
use Chill\PersonBundle\Entity\Person;
|
||||
|
||||
trait PreparePersonTrait
|
||||
@@ -25,15 +27,16 @@ trait PreparePersonTrait
|
||||
* - gender
|
||||
*
|
||||
* This person should not be persisted in a database
|
||||
*
|
||||
* @return Person
|
||||
*/
|
||||
protected function preparePerson(Center $center): \Chill\PersonBundle\Entity\Person
|
||||
protected function preparePerson(Center $center): Person
|
||||
{
|
||||
$gender = new Gender();
|
||||
$gender->setLabel([GenderEnum::MALE]);
|
||||
|
||||
return (new Person())
|
||||
->setCenter($center)
|
||||
->setFirstName('test firstname')
|
||||
->setLastName('default lastname')
|
||||
->setGender(Person::MALE_GENDER);
|
||||
->setGender($gender);
|
||||
}
|
||||
}
|
||||
|
Reference in New Issue
Block a user