Add and update test handlers for suggested users retrieval

Introduced new test files for workflow handlers and adjusted existing `getSuggestedUsers` methods to handle related entity checks and duplicates removal. Also, modified repos to align with test dependencies.
This commit is contained in:
2024-10-22 23:15:03 +02:00
parent 418794e586
commit c877076429
10 changed files with 410 additions and 29 deletions

View File

@@ -19,9 +19,9 @@ use Doctrine\ORM\EntityRepository;
use Doctrine\ORM\NonUniqueResultException;
use Doctrine\Persistence\ObjectRepository;
readonly class AccompanyingPeriodWorkEvaluationDocumentRepository implements ObjectRepository, AssociatedEntityToStoredObjectInterface
class AccompanyingPeriodWorkEvaluationDocumentRepository implements ObjectRepository, AssociatedEntityToStoredObjectInterface
{
private EntityRepository $repository;
private readonly EntityRepository $repository;
public function __construct(EntityManagerInterface $em)
{

View File

@@ -22,11 +22,11 @@ use Doctrine\ORM\Query\ResultSetMappingBuilder;
use Doctrine\ORM\QueryBuilder;
use Doctrine\Persistence\ObjectRepository;
final readonly class AccompanyingPeriodWorkRepository implements ObjectRepository
class AccompanyingPeriodWorkRepository implements ObjectRepository
{
private EntityRepository $repository;
private readonly EntityRepository $repository;
public function __construct(private EntityManagerInterface $em)
public function __construct(private readonly EntityManagerInterface $em)
{
$this->repository = $em->getRepository(AccompanyingPeriodWork::class);
}