exports tests: move tests in sub-folder, adapt namespace + fix errors

This commit is contained in:
Mathieu Jaumotte 2022-09-06 15:34:42 +02:00
parent eedfa60bea
commit d3a0c4c283
32 changed files with 68 additions and 72 deletions

View File

@ -34,7 +34,7 @@ class MaritalStatusFilter implements FilterInterface
$this->translatableStringHelper = $translatableStringHelper;
}
public function addRole()
public function addRole(): ?string
{
return null;
}

View File

@ -9,7 +9,7 @@
declare(strict_types=1);
namespace Chill\PersonBundle\Tests\Export\Aggregator;
namespace Chill\PersonBundle\Tests\Export\Aggregator\PersonAggregators;
use Chill\MainBundle\Test\Export\AbstractAggregatorTest;
use DateTime;
@ -21,7 +21,7 @@ use DateTime;
final class AgeAggregatorTest extends AbstractAggregatorTest
{
/**
* @var \Chill\PersonBundle\Export\Aggregator\AgeAggregator
* @var \Chill\PersonBundle\Export\Aggregator\PersonAggregators\AgeAggregator
*/
private $aggregator;

View File

@ -9,7 +9,7 @@
declare(strict_types=1);
namespace Chill\PersonBundle\Tests\Export\Aggregator;
namespace Chill\PersonBundle\Tests\Export\Aggregator\PersonAggregators;
use Chill\MainBundle\Test\Export\AbstractAggregatorTest;
@ -20,7 +20,7 @@ use Chill\MainBundle\Test\Export\AbstractAggregatorTest;
final class GenderAggregatorTest extends AbstractAggregatorTest
{
/**
* @var \Chill\PersonBundle\Export\Aggregator\GenderAggregator
* @var \Chill\PersonBundle\Export\Aggregator\PersonAggregators\GenderAggregator
*/
private $aggregator;

View File

@ -9,7 +9,7 @@
declare(strict_types=1);
namespace Chill\PersonBundle\Tests\Export\Aggregator;
namespace Chill\PersonBundle\Tests\Export\Aggregator\PersonAggregators;
use Chill\MainBundle\Test\Export\AbstractAggregatorTest;
@ -20,7 +20,7 @@ use Chill\MainBundle\Test\Export\AbstractAggregatorTest;
final class NationalityAggregatorTest extends AbstractAggregatorTest
{
/**
* @var \Chill\PersonBundle\Export\Aggregator\NationalityAggregator
* @var \Chill\PersonBundle\Export\Aggregator\PersonAggregators\NationalityAggregator
*/
private $aggregator;

View File

@ -9,10 +9,10 @@
declare(strict_types=1);
namespace Chill\PersonBundle\Tests\Export\Aggregator;
namespace Chill\PersonBundle\Tests\Export\Aggregator\SocialWorkAggregators;
use Chill\MainBundle\Test\Export\AbstractAggregatorTest;
use Chill\PersonBundle\Export\Aggregator\ActionTypeAggregator;
use Chill\PersonBundle\Export\Aggregator\SocialWorkAggregators\ActionTypeAggregator;
/**
* @internal

View File

@ -9,10 +9,10 @@
declare(strict_types=1);
namespace Chill\PersonBundle\Tests\Export\Aggregator;
namespace Chill\PersonBundle\Tests\Export\Aggregator\SocialWorkAggregators;
use Chill\MainBundle\Test\Export\AbstractAggregatorTest;
use Chill\PersonBundle\Export\Aggregator\GoalAggregator;
use Chill\PersonBundle\Export\Aggregator\SocialWorkAggregators\GoalAggregator;
/**
* @internal

View File

@ -9,10 +9,10 @@
declare(strict_types=1);
namespace Chill\PersonBundle\Tests\Export\Aggregator;
namespace Chill\PersonBundle\Tests\Export\Aggregator\SocialWorkAggregators;
use Chill\MainBundle\Test\Export\AbstractAggregatorTest;
use Chill\PersonBundle\Export\Aggregator\ReferrerAggregator;
use Chill\PersonBundle\Export\Aggregator\SocialWorkAggregators\ReferrerAggregator;
/**
* @internal

View File

@ -9,10 +9,10 @@
declare(strict_types=1);
namespace Chill\PersonBundle\Tests\Export\Aggregator;
namespace Chill\PersonBundle\Tests\Export\Aggregator\SocialWorkAggregators;
use Chill\MainBundle\Test\Export\AbstractAggregatorTest;
use Chill\PersonBundle\Export\Aggregator\ResultAggregator;
use Chill\PersonBundle\Export\Aggregator\SocialWorkAggregators\ResultAggregator;
/**
* @internal

View File

@ -9,10 +9,10 @@
declare(strict_types=1);
namespace Chill\PersonBundle\Tests\Export\Filter;
namespace Chill\PersonBundle\Tests\Export\Filter\AccompanyingCourseFilters;
use Chill\MainBundle\Test\Export\AbstractFilterTest;
use Chill\PersonBundle\Export\Filter\ActiveOnDateFilter;
use Chill\PersonBundle\Export\Filter\AccompanyingCourseFilters\ActiveOnDateFilter;
use DateTime;
use Doctrine\ORM\EntityManagerInterface;
use Symfony\Component\HttpFoundation\Request;

View File

@ -9,10 +9,10 @@
declare(strict_types=1);
namespace Chill\PersonBundle\Tests\Export\Filter;
namespace Chill\PersonBundle\Tests\Export\Filter\AccompanyingCourseFilters;
use Chill\MainBundle\Test\Export\AbstractFilterTest;
use Chill\PersonBundle\Export\Filter\ActiveOneDayBetweenDatesFilter;
use Chill\PersonBundle\Export\Filter\AccompanyingCourseFilters\ActiveOneDayBetweenDatesFilter;
use DateTime;
use Doctrine\ORM\EntityManagerInterface;
use Symfony\Component\HttpFoundation\Request;

View File

@ -9,11 +9,11 @@
declare(strict_types=1);
namespace Export\Filter;
namespace Chill\PersonBundle\Tests\Export\Filter\AccompanyingCourseFilters;
use Chill\ActivityBundle\Entity\ActivityType;
use Chill\MainBundle\Test\Export\AbstractFilterTest;
use Chill\PersonBundle\Export\Filter\ActivityTypeFilter;
use Chill\PersonBundle\Export\Filter\AccompanyingCourseFilters\ActivityTypeFilter;
use Doctrine\ORM\EntityManagerInterface;
use Symfony\Component\HttpFoundation\Request;

View File

@ -9,11 +9,11 @@
declare(strict_types=1);
namespace Export\Filter;
namespace Chill\PersonBundle\Tests\Export\Filter\AccompanyingCourseFilters;;
use Chill\MainBundle\Entity\Location;
use Chill\MainBundle\Test\Export\AbstractFilterTest;
use Chill\PersonBundle\Export\Filter\AdministrativeLocationFilter;
use Chill\PersonBundle\Export\Filter\AccompanyingCourseFilters\AdministrativeLocationFilter;
use Doctrine\ORM\EntityManagerInterface;
use Symfony\Component\HttpFoundation\Request;

View File

@ -9,11 +9,11 @@
declare(strict_types=1);
namespace Chill\PersonBundle\Tests\Export\Filter;
namespace Chill\PersonBundle\Tests\Export\Filter\AccompanyingCourseFilters;
use Chill\MainBundle\Test\Export\AbstractFilterTest;
use Chill\PersonBundle\Entity\AccompanyingPeriod\ClosingMotive;
use Chill\PersonBundle\Export\Filter\ClosingMotiveFilter;
use Chill\PersonBundle\Export\Filter\AccompanyingCourseFilters\ClosingMotiveFilter;
use Doctrine\ORM\EntityManagerInterface;
/**

View File

@ -9,10 +9,10 @@
declare(strict_types=1);
namespace Chill\PersonBundle\Tests\Export\Filter;
namespace Chill\PersonBundle\Tests\Export\Filter\AccompanyingCourseFilters;
use Chill\MainBundle\Test\Export\AbstractFilterTest;
use Chill\PersonBundle\Export\Filter\ConfidentialFilter;
use Chill\PersonBundle\Export\Filter\AccompanyingCourseFilters\ConfidentialFilter;
use Doctrine\ORM\EntityManagerInterface;
/**

View File

@ -9,17 +9,17 @@
declare(strict_types=1);
namespace Chill\PersonBundle\Tests\Export\Filter;
namespace Chill\PersonBundle\Tests\Export\Filter\AccompanyingCourseFilters;
use Chill\MainBundle\Test\Export\AbstractFilterTest;
use Chill\PersonBundle\Export\Filter\UserJobFilter;
use Chill\PersonBundle\Export\Filter\AccompanyingCourseFilters\UserJobFilter;
use Doctrine\ORM\EntityManagerInterface;
/**
* @internal
* @coversNothing
*/
final class UserJobFilterTest extends AbstractFilterTest
final class CurrentUserJobFilterTest extends AbstractFilterTest
{
private UserJobFilter $filter;

View File

@ -9,17 +9,17 @@
declare(strict_types=1);
namespace Chill\PersonBundle\Tests\Export\Filter;
namespace Chill\PersonBundle\Tests\Export\Filter\AccompanyingCourseFilters;
use Chill\MainBundle\Test\Export\AbstractFilterTest;
use Chill\PersonBundle\Export\Filter\UserScopeFilter;
use Chill\PersonBundle\Export\Filter\AccompanyingCourseFilters\UserScopeFilter;
use Doctrine\ORM\EntityManagerInterface;
/**
* @internal
* @coversNothing
*/
final class UserScopeFilterTest extends AbstractFilterTest
final class CurrentUserScopeFilterTest extends AbstractFilterTest
{
private UserScopeFilter $filter;

View File

@ -9,10 +9,10 @@
declare(strict_types=1);
namespace Chill\PersonBundle\Tests\Export\Filter;
namespace Chill\PersonBundle\Tests\Export\Filter\AccompanyingCourseFilters;
use Chill\MainBundle\Test\Export\AbstractFilterTest;
use Chill\PersonBundle\Export\Filter\EmergencyFilter;
use Chill\PersonBundle\Export\Filter\AccompanyingCourseFilters\EmergencyFilter;
use Doctrine\ORM\EntityManagerInterface;
/**

View File

@ -9,11 +9,11 @@
declare(strict_types=1);
namespace Export\Filter;
namespace Chill\PersonBundle\Tests\Export\Filter\AccompanyingCourseFilters;
use Chill\MainBundle\Test\Export\AbstractFilterTest;
use Chill\PersonBundle\Entity\SocialWork\Evaluation;
use Chill\PersonBundle\Export\Filter\EvaluationFilter;
use Chill\PersonBundle\Export\Filter\AccompanyingCourseFilters\EvaluationFilter;
use Doctrine\ORM\EntityManagerInterface;
use Symfony\Component\HttpFoundation\Request;

View File

@ -9,10 +9,10 @@
declare(strict_types=1);
namespace Export\Filter;
namespace Chill\PersonBundle\Tests\Export\Filter\AccompanyingCourseFilters;
use Chill\MainBundle\Test\Export\AbstractFilterTest;
use Chill\PersonBundle\Export\Filter\GeographicalUnitStatFilter;
use Chill\PersonBundle\Export\Filter\AccompanyingCourseFilters\GeographicalUnitStatFilter;
use DateTime;
use Doctrine\ORM\EntityManagerInterface;
use Symfony\Component\HttpFoundation\Request;

View File

@ -9,10 +9,10 @@
declare(strict_types=1);
namespace Chill\PersonBundle\Tests\Export\Filter;
namespace Chill\PersonBundle\Tests\Export\Filter\AccompanyingCourseFilters;
use Chill\MainBundle\Test\Export\AbstractFilterTest;
use Chill\PersonBundle\Export\Filter\IntensityFilter;
use Chill\PersonBundle\Export\Filter\AccompanyingCourseFilters\IntensityFilter;
use Doctrine\ORM\EntityManagerInterface;
/**

View File

@ -9,10 +9,10 @@
declare(strict_types=1);
namespace Chill\PersonBundle\Tests\Export\Filter;
namespace Chill\PersonBundle\Tests\Export\Filter\AccompanyingCourseFilters;
use Chill\MainBundle\Test\Export\AbstractFilterTest;
use Chill\PersonBundle\Export\Filter\OpenBetweenDatesFilter;
use Chill\PersonBundle\Export\Filter\AccompanyingCourseFilters\OpenBetweenDatesFilter;
use DateTime;
use Doctrine\ORM\EntityManagerInterface;
use Symfony\Component\HttpFoundation\Request;

View File

@ -9,11 +9,11 @@
declare(strict_types=1);
namespace Chill\PersonBundle\Tests\Export\Filter;
namespace Chill\PersonBundle\Tests\Export\Filter\AccompanyingCourseFilters;
use Chill\MainBundle\Test\Export\AbstractFilterTest;
use Chill\PersonBundle\Entity\AccompanyingPeriod\Origin;
use Chill\PersonBundle\Export\Filter\OriginFilter;
use Chill\PersonBundle\Export\Filter\AccompanyingCourseFilters\OriginFilter;
use Doctrine\ORM\EntityManagerInterface;
/**

View File

@ -9,11 +9,11 @@
declare(strict_types=1);
namespace Chill\PersonBundle\Tests\Export\Filter;
namespace Chill\PersonBundle\Tests\Export\Filter\AccompanyingCourseFilters;
use Chill\MainBundle\Entity\User;
use Chill\MainBundle\Test\Export\AbstractFilterTest;
use Chill\PersonBundle\Export\Filter\ReferrerFilter;
use Chill\PersonBundle\Export\Filter\AccompanyingCourseFilters\ReferrerFilter;
use Doctrine\ORM\EntityManagerInterface;
use Symfony\Component\HttpFoundation\Request;

View File

@ -9,10 +9,10 @@
declare(strict_types=1);
namespace Export\Filter;
namespace Chill\PersonBundle\Tests\Export\Filter\AccompanyingCourseFilters;
use Chill\MainBundle\Test\Export\AbstractFilterTest;
use Chill\PersonBundle\Export\Filter\RequestorFilter;
use Chill\PersonBundle\Export\Filter\AccompanyingCourseFilters\RequestorFilter;
use Doctrine\ORM\EntityManagerInterface;
use Symfony\Component\HttpFoundation\Request;

View File

@ -9,11 +9,11 @@
declare(strict_types=1);
namespace Export\Filter;
namespace Chill\PersonBundle\Tests\Export\Filter\AccompanyingCourseFilters;
use Chill\MainBundle\Test\Export\AbstractFilterTest;
use Chill\PersonBundle\Entity\SocialWork\SocialAction;
use Chill\PersonBundle\Export\Filter\SocialActionFilter;
use Chill\PersonBundle\Export\Filter\AccompanyingCourseFilters\SocialActionFilter;
use Doctrine\ORM\EntityManagerInterface;
use Symfony\Component\HttpFoundation\Request;

View File

@ -9,11 +9,11 @@
declare(strict_types=1);
namespace Chill\PersonBundle\Tests\Export\Filter;
namespace Chill\PersonBundle\Tests\Export\Filter\AccompanyingCourseFilters;
use Chill\MainBundle\Test\Export\AbstractFilterTest;
use Chill\PersonBundle\Entity\SocialWork\SocialIssue;
use Chill\PersonBundle\Export\Filter\SocialIssueFilter;
use Chill\PersonBundle\Export\Filter\AccompanyingCourseFilters\SocialIssueFilter;
use Doctrine\ORM\EntityManagerInterface;
/**

View File

@ -9,11 +9,11 @@
declare(strict_types=1);
namespace Chill\PersonBundle\Tests\Export\Filter;
namespace Chill\PersonBundle\Tests\Export\Filter\AccompanyingCourseFilters;
use Chill\MainBundle\Test\Export\AbstractFilterTest;
use Chill\PersonBundle\Entity\AccompanyingPeriod;
use Chill\PersonBundle\Export\Filter\StepFilter;
use Chill\PersonBundle\Export\Filter\AccompanyingCourseFilters\StepFilter;
/**
* @internal

View File

@ -9,9 +9,10 @@
declare(strict_types=1);
namespace Chill\PersonBundle\Tests\Export\Filter;
namespace Chill\PersonBundle\Tests\Export\Filter\PersonFilters;
use Chill\MainBundle\Test\Export\AbstractFilterTest;
use Chill\PersonBundle\Export\Filter\PersonFilters\BirthdateFilter;
use DateTime;
use Symfony\Component\DependencyInjection\Exception\ServiceNotFoundException;
@ -21,10 +22,7 @@ use Symfony\Component\DependencyInjection\Exception\ServiceNotFoundException;
*/
final class AccompanyingPeriodFilterTest extends AbstractFilterTest
{
/**
* @var \Chill\PersonBundle\Export\Filter\BirthdateFilter
*/
private $filter;
private BirthdateFilter $filter;
protected function setUp(): void
{

View File

@ -9,9 +9,10 @@
declare(strict_types=1);
namespace Chill\PersonBundle\Tests\Export\Filter;
namespace Chill\PersonBundle\Tests\Export\Filter\PersonFilters;
use Chill\MainBundle\Test\Export\AbstractFilterTest;
use Chill\PersonBundle\Export\Filter\PersonFilters\BirthdateFilter;
use DateTime;
/**
@ -20,10 +21,7 @@ use DateTime;
*/
final class BirthdayFilterTest extends AbstractFilterTest
{
/**
* @var \Chill\PersonBundle\Export\Filter\BirthdateFilter
*/
private $filter;
private BirthdateFilter $filter;
protected function setUp(): void
{

View File

@ -9,10 +9,11 @@
declare(strict_types=1);
namespace Chill\PersonBundle\Tests\Export\Filter;
namespace Chill\PersonBundle\Tests\Export\Filter\PersonFilters;
use Chill\MainBundle\Test\Export\AbstractFilterTest;
use Chill\PersonBundle\Entity\Person;
use Chill\PersonBundle\Export\Filter\PersonFilters\GenderFilter;
/**
* @internal
@ -20,10 +21,7 @@ use Chill\PersonBundle\Entity\Person;
*/
final class GenderFilterTest extends AbstractFilterTest
{
/**
* @var \Chill\PersonBundle\Export\Filter\GenderFilter
*/
private $filter;
private GenderFilter $filter;
protected function setUp(): void
{

View File

@ -9,9 +9,10 @@
declare(strict_types=1);
namespace Chill\PersonBundle\Tests\Export\Filter;
namespace Chill\PersonBundle\Tests\Export\Filter\SocialWorkFilters;
use Chill\MainBundle\Test\Export\AbstractFilterTest;
use Chill\PersonBundle\Export\Filter\SocialWorkFilters\JobFilter;
use Doctrine\ORM\EntityManagerInterface;
/**

View File

@ -9,9 +9,10 @@
declare(strict_types=1);
namespace Chill\PersonBundle\Tests\Export\Filter;
namespace Chill\PersonBundle\Tests\Export\Filter\SocialWorkFilters;
use Chill\MainBundle\Test\Export\AbstractFilterTest;
use Chill\PersonBundle\Export\Filter\SocialWorkFilters\ScopeFilter;
use Doctrine\ORM\EntityManagerInterface;
/**