Docgen/action add missing goals

This commit is contained in:
2022-01-10 09:35:26 +00:00
parent 78cf817921
commit efc3e3915b
26 changed files with 332 additions and 98 deletions

View File

@@ -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();

View File

@@ -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()) {