mirror of
https://gitlab.com/Chill-Projet/chill-bundles.git
synced 2025-08-29 11:03:50 +00:00
Fix phpunit pipeline
This commit is contained in:
@@ -80,14 +80,15 @@ class LoadPeople extends AbstractFixture implements ContainerAwareInterface, Ord
|
||||
*/
|
||||
protected array $cacheUsers = [];
|
||||
|
||||
/**
|
||||
* @var array|Gender[]
|
||||
*/
|
||||
protected array $cacheGenders = [];
|
||||
|
||||
protected Generator $faker;
|
||||
|
||||
protected NativeLoader $loader;
|
||||
|
||||
// private array $genders = [GenderEnum::MALE, GenderEnum::FEMALE, GenderEnum::NEUTRAL];
|
||||
|
||||
private array $peoples = [
|
||||
[
|
||||
'lastName' => 'Depardieu',
|
||||
@@ -124,7 +125,7 @@ class LoadPeople extends AbstractFixture implements ContainerAwareInterface, Ord
|
||||
'maritalStatus' => 'ms_divorce',
|
||||
],
|
||||
[
|
||||
// to have a person with same birthdate of Gérard Depardieu
|
||||
// to have a person with same birthdate as Gérard Depardieu
|
||||
'lastName' => 'Van Snick',
|
||||
'firstName' => 'Bart',
|
||||
'birthdate' => '1948-12-27',
|
||||
@@ -281,7 +282,7 @@ class LoadPeople extends AbstractFixture implements ContainerAwareInterface, Ord
|
||||
public function getRandomGender(int $nullPercentage = 50): ?Gender
|
||||
{
|
||||
if (0 === \count($this->cacheGenders)) {
|
||||
$this->cacheGenders = $this->genderRepository->findAll();
|
||||
$this->cacheGenders = $this->genderRepository->findByActiveOrdered();
|
||||
}
|
||||
|
||||
if (\random_int(0, 100) > $nullPercentage) {
|
||||
|
Reference in New Issue
Block a user