mirror of
https://gitlab.com/Chill-Projet/chill-bundles.git
synced 2025-08-22 07:33:50 +00:00
Docgen/action add missing goals
This commit is contained in:
@@ -17,6 +17,7 @@ use Chill\PersonBundle\Entity\Person;
|
||||
use Chill\PersonBundle\Validator\Constraints\Person\PersonHasCenter;
|
||||
use Chill\PersonBundle\Validator\Constraints\Person\PersonHasCenterValidator;
|
||||
use Prophecy\Argument;
|
||||
use Prophecy\PhpUnit\ProphecyTrait;
|
||||
use Symfony\Component\DependencyInjection\ParameterBag\ParameterBagInterface;
|
||||
use Symfony\Component\Validator\Test\ConstraintValidatorTestCase;
|
||||
|
||||
@@ -26,6 +27,8 @@ use Symfony\Component\Validator\Test\ConstraintValidatorTestCase;
|
||||
*/
|
||||
final class PersonHasCenterValidatorTest extends ConstraintValidatorTestCase
|
||||
{
|
||||
use ProphecyTrait;
|
||||
|
||||
public function testValidateRequired()
|
||||
{
|
||||
$constraint = $this->getConstraint();
|
||||
|
@@ -37,7 +37,7 @@ final class PersonValidationTest extends KernelTestCase
|
||||
{
|
||||
$person = (new Person())
|
||||
->setBirthdate(new Datetime('+2 months'));
|
||||
$errors = $this->validator->validate($person, null, ['creation']);
|
||||
$errors = $this->validator->validate($person, null);
|
||||
|
||||
foreach ($errors->getIterator() as $error) {
|
||||
if (Birthdate::BIRTHDATE_INVALID_CODE === $error->getCode()) {
|
||||
@@ -59,7 +59,7 @@ final class PersonValidationTest extends KernelTestCase
|
||||
{
|
||||
$person = (new Person())
|
||||
->setFirstname(str_repeat('a', 500));
|
||||
$errors = $this->validator->validate($person, null, ['creation']);
|
||||
$errors = $this->validator->validate($person, null);
|
||||
|
||||
foreach ($errors->getIterator() as $error) {
|
||||
if (Length::TOO_LONG_ERROR === $error->getCode()) {
|
||||
|
Reference in New Issue
Block a user