mirror of
https://gitlab.com/Chill-Projet/chill-bundles.git
synced 2025-06-07 18:44:08 +00:00
fix: Fix tests.
This commit is contained in:
parent
7fd45d5735
commit
1509fcc2e9
@ -1,14 +1,18 @@
|
|||||||
<?php
|
<?php
|
||||||
|
|
||||||
|
declare(strict_types=1);
|
||||||
|
|
||||||
namespace Validator\Person;
|
namespace Validator\Person;
|
||||||
|
|
||||||
use Chill\MainBundle\Entity\Center;
|
use Chill\MainBundle\Entity\Center;
|
||||||
|
use Chill\MainBundle\Security\Resolver\CenterResolverDispatcher;
|
||||||
use Chill\PersonBundle\Entity\Person;
|
use Chill\PersonBundle\Entity\Person;
|
||||||
use Chill\PersonBundle\Validator\Constraints\Person\PersonHasCenter;
|
use Chill\PersonBundle\Validator\Constraints\Person\PersonHasCenter;
|
||||||
use Chill\PersonBundle\Validator\Constraints\Person\PersonHasCenterValidator;
|
use Chill\PersonBundle\Validator\Constraints\Person\PersonHasCenterValidator;
|
||||||
use Symfony\Component\DependencyInjection\ParameterBag\ParameterBagInterface;
|
use Symfony\Component\DependencyInjection\ParameterBag\ParameterBagInterface;
|
||||||
|
use Symfony\Component\Validator\Test\ConstraintValidatorTestCase;
|
||||||
|
|
||||||
class PersonHasCenterValidatorTest extends \Symfony\Component\Validator\Test\ConstraintValidatorTestCase
|
class PersonHasCenterValidatorTest extends ConstraintValidatorTestCase
|
||||||
{
|
{
|
||||||
public function testValidateRequired()
|
public function testValidateRequired()
|
||||||
{
|
{
|
||||||
@ -42,9 +46,10 @@ class PersonHasCenterValidatorTest extends \Symfony\Component\Validator\Test\Con
|
|||||||
'validation' => [
|
'validation' => [
|
||||||
'center_required' => true
|
'center_required' => true
|
||||||
]
|
]
|
||||||
])
|
]);
|
||||||
;
|
|
||||||
|
|
||||||
return new PersonHasCenterValidator($parameterBag);
|
$centerResolverDispatcher = $this->createMock(CenterResolverDispatcher::class);
|
||||||
|
|
||||||
|
return new PersonHasCenterValidator($parameterBag, $centerResolverDispatcher);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user