mirror of
https://gitlab.com/Chill-Projet/chill-bundles.git
synced 2025-09-05 14:25:00 +00:00
Fix tests
This commit is contained in:
@@ -27,7 +27,7 @@ final class CountAccompanyingPeriodWorkTest extends AbstractExportTest
|
||||
{
|
||||
self::bootKernel();
|
||||
|
||||
$this->export = self::$container->get('chill.person.export.count_social_work_actions');
|
||||
$this->export = self::$container->get(CountAccompanyingPeriodWork::class);
|
||||
}
|
||||
|
||||
public function getExport()
|
||||
|
@@ -12,6 +12,7 @@ declare(strict_types=1);
|
||||
namespace Chill\PersonBundle\Tests\Export\Export;
|
||||
|
||||
use Chill\MainBundle\Test\Export\AbstractExportTest;
|
||||
use Chill\PersonBundle\Export\Export\CountPerson;
|
||||
|
||||
/**
|
||||
* Test CountPerson export.
|
||||
@@ -30,7 +31,7 @@ final class CountPersonTest extends AbstractExportTest
|
||||
{
|
||||
self::bootKernel();
|
||||
|
||||
$this->export = self::$container->get('chill.person.export.count_person');
|
||||
$this->export = self::$container->get(CountPerson::class);
|
||||
}
|
||||
|
||||
public function getExport()
|
||||
|
@@ -11,6 +11,7 @@ declare(strict_types=1);
|
||||
|
||||
namespace Chill\PersonBundle\Tests\Export\Export;
|
||||
|
||||
use Chill\MainBundle\Service\RollingDate\RollingDate;
|
||||
use Chill\MainBundle\Test\Export\AbstractExportTest;
|
||||
use Chill\PersonBundle\Export\Export\ListPerson;
|
||||
use DateTime;
|
||||
@@ -32,7 +33,7 @@ final class ListPersonTest extends AbstractExportTest
|
||||
{
|
||||
self::bootKernel();
|
||||
|
||||
$this->export = self::$container->get('chill.person.export.list_person');
|
||||
$this->export = self::$container->get(ListPerson::class);
|
||||
|
||||
$request = $this->prophesize()
|
||||
->willExtend(\Symfony\Component\HttpFoundation\Request::class);
|
||||
@@ -48,20 +49,17 @@ final class ListPersonTest extends AbstractExportTest
|
||||
return $this->export;
|
||||
}
|
||||
|
||||
public function getFormData(): array
|
||||
public function getFormData(): iterable
|
||||
{
|
||||
return [
|
||||
foreach ([
|
||||
['fields' => ['id', 'firstName', 'lastName']],
|
||||
['fields' => ['id', 'birthdate', 'gender', 'memo', 'email', 'phonenumber']],
|
||||
['fields' => ['firstName', 'lastName', 'phonenumber']],
|
||||
['fields' => ['id', 'nationality']],
|
||||
['fields' => ['id', 'countryOfBirth']],
|
||||
['fields' => ['id', 'address_street_address_1',
|
||||
'address_street_address_2', 'address_valid_from',
|
||||
'address_postcode_label', 'address_postcode_code',
|
||||
'address_country_name', 'address_country_code', ],
|
||||
'address_date' => DateTime::createFromFormat('Y-m-d', '2016-06-12'), ],
|
||||
];
|
||||
] as $base) {
|
||||
yield [...$base, 'address_date' => new \DateTimeImmutable('today') ];
|
||||
}
|
||||
}
|
||||
|
||||
public function getModifiersCombination(): array
|
||||
|
Reference in New Issue
Block a user