From 1488c6bbea87104276a9db2d990ccff8bae286f1 Mon Sep 17 00:00:00 2001 From: Marijn Doeve Date: Tue, 23 Jun 2026 22:55:27 +0200 Subject: [PATCH] Run updated tools --- config/reference.php | 6 +++--- src/Command/ClaimSeasonCommand.php | 2 ++ src/Command/MakeAdminCommand.php | 2 ++ src/Entity/GivenAnswer.php | 6 +++--- src/Helpers/Base64.php | 2 ++ src/Repository/CandidateRepository.php | 4 +++- src/Repository/QuestionRepository.php | 4 +++- src/Repository/QuizCandidateRepository.php | 4 +++- src/Repository/QuizRepository.php | 4 +++- src/Repository/SeasonRepository.php | 4 +++- src/Repository/UserRepository.php | 4 +++- src/Security/Voter/SeasonVoter.php | 4 +++- 12 files changed, 33 insertions(+), 13 deletions(-) diff --git a/config/reference.php b/config/reference.php index e0ea2b9..63c1e13 100644 --- a/config/reference.php +++ b/config/reference.php @@ -727,7 +727,7 @@ use Symfony\Component\Config\Loader\ParamConfigurator as Param; * servicename?: scalar|Param|null, // Overrules dbname parameter if given and used as SERVICE_NAME or SID connection parameter for Oracle depending on the service parameter. * sessionMode?: scalar|Param|null, // The session mode to use for the oci8 driver * server?: scalar|Param|null, // The name of a running database server to connect to for SQL Anywhere. - * default_dbname?: scalar|Param|null, // Override the default database (postgres) to connect to for PostgreSQL connexion. + * default_dbname?: scalar|Param|null, // Override the default database (postgres) to connect to for PostgreSQL connection. * sslmode?: scalar|Param|null, // Determines whether or with what priority a SSL TCP/IP connection will be negotiated with the server for PostgreSQL. * sslrootcert?: scalar|Param|null, // The name of a file containing SSL certificate authority (CA) certificate(s). If the file exists, the server's certificate will be verified to be signed by one of these authorities. * sslcert?: scalar|Param|null, // The path to the SSL client certificate file for PostgreSQL. @@ -773,7 +773,7 @@ use Symfony\Component\Config\Loader\ParamConfigurator as Param; * servicename?: scalar|Param|null, // Overrules dbname parameter if given and used as SERVICE_NAME or SID connection parameter for Oracle depending on the service parameter. * sessionMode?: scalar|Param|null, // The session mode to use for the oci8 driver * server?: scalar|Param|null, // The name of a running database server to connect to for SQL Anywhere. - * default_dbname?: scalar|Param|null, // Override the default database (postgres) to connect to for PostgreSQL connexion. + * default_dbname?: scalar|Param|null, // Override the default database (postgres) to connect to for PostgreSQL connection. * sslmode?: scalar|Param|null, // Determines whether or with what priority a SSL TCP/IP connection will be negotiated with the server for PostgreSQL. * sslrootcert?: scalar|Param|null, // The name of a file containing SSL certificate authority (CA) certificate(s). If the file exists, the server's certificate will be verified to be signed by one of these authorities. * sslcert?: scalar|Param|null, // The path to the SSL client certificate file for PostgreSQL. @@ -852,7 +852,7 @@ use Symfony\Component\Config\Loader\ParamConfigurator as Param; * lock_path?: scalar|Param|null, // Default: "%kernel.cache_dir%/doctrine/orm/slc/filelock" * lock_lifetime?: scalar|Param|null, // Default: 60 * type?: scalar|Param|null, // Default: "default" - * lifetime?: scalar|Param|null, // Default: 0 + * lifetime?: scalar|Param|null, // Default: null * service?: scalar|Param|null, * name?: scalar|Param|null, * }>, diff --git a/src/Command/ClaimSeasonCommand.php b/src/Command/ClaimSeasonCommand.php index e6dfd1b..89bc006 100644 --- a/src/Command/ClaimSeasonCommand.php +++ b/src/Command/ClaimSeasonCommand.php @@ -12,7 +12,9 @@ use Symfony\Component\Console\Style\SymfonyStyle; use Tvdt\Entity\Season; use Tvdt\Repository\SeasonRepository; use Tvdt\Repository\UserRepository; +use Tvdt\Tests\Command\ClaimSeasonCommandTest; +/** @see ClaimSeasonCommandTest */ #[AsCommand( name: 'tvdt:claim-season', description: 'Give a user owner rights on a season', diff --git a/src/Command/MakeAdminCommand.php b/src/Command/MakeAdminCommand.php index 4c3d1c2..0a637d8 100644 --- a/src/Command/MakeAdminCommand.php +++ b/src/Command/MakeAdminCommand.php @@ -9,7 +9,9 @@ use Symfony\Component\Console\Attribute\AsCommand; use Symfony\Component\Console\Command\Command; use Symfony\Component\Console\Style\SymfonyStyle; use Tvdt\Repository\UserRepository; +use Tvdt\Tests\Command\MakeAdminCommandTest; +/** @see MakeAdminCommandTest */ #[AsCommand( name: 'tvdt:make-admin', description: 'Give a user the role admin', diff --git a/src/Entity/GivenAnswer.php b/src/Entity/GivenAnswer.php index 64387da..bd778de 100644 --- a/src/Entity/GivenAnswer.php +++ b/src/Entity/GivenAnswer.php @@ -31,14 +31,14 @@ class GivenAnswer public function __construct( #[ORM\JoinColumn(nullable: false)] #[ORM\ManyToOne(inversedBy: 'givenAnswers')] - private(set) Candidate $candidate, + public private(set) Candidate $candidate, #[ORM\JoinColumn(nullable: false, onDelete: 'CASCADE')] #[ORM\ManyToOne] - private(set) Quiz $quiz, + public private(set) Quiz $quiz, #[ORM\JoinColumn(nullable: false)] #[ORM\ManyToOne(inversedBy: 'givenAnswers')] - private(set) Answer $answer, + public private(set) Answer $answer, ) {} } diff --git a/src/Helpers/Base64.php b/src/Helpers/Base64.php index 647ca68..db976dc 100644 --- a/src/Helpers/Base64.php +++ b/src/Helpers/Base64.php @@ -5,7 +5,9 @@ declare(strict_types=1); namespace Tvdt\Helpers; use Safe\Exceptions\UrlException; +use Tvdt\Tests\Helpers\Base64Test; +/** @see Base64Test */ class Base64 { public static function base64UrlEncode(string $input): string diff --git a/src/Repository/CandidateRepository.php b/src/Repository/CandidateRepository.php index 8c8bf20..8ba03f5 100644 --- a/src/Repository/CandidateRepository.php +++ b/src/Repository/CandidateRepository.php @@ -10,8 +10,10 @@ use Safe\Exceptions\UrlException; use Tvdt\Entity\Candidate; use Tvdt\Entity\Season; use Tvdt\Helpers\Base64; +use Tvdt\Tests\Repository\CandidateRepositoryTest; -/** @extends ServiceEntityRepository */ +/** @extends ServiceEntityRepository + * @see CandidateRepositoryTest */ class CandidateRepository extends ServiceEntityRepository { public function __construct(ManagerRegistry $registry) diff --git a/src/Repository/QuestionRepository.php b/src/Repository/QuestionRepository.php index 045a5a6..8a146a3 100644 --- a/src/Repository/QuestionRepository.php +++ b/src/Repository/QuestionRepository.php @@ -8,8 +8,10 @@ use Doctrine\Bundle\DoctrineBundle\Repository\ServiceEntityRepository; use Doctrine\Persistence\ManagerRegistry; use Tvdt\Entity\Candidate; use Tvdt\Entity\Question; +use Tvdt\Tests\Repository\QuestionRepositoryTest; -/** @extends ServiceEntityRepository */ +/** @extends ServiceEntityRepository + * @see QuestionRepositoryTest */ class QuestionRepository extends ServiceEntityRepository { public function __construct(ManagerRegistry $registry) diff --git a/src/Repository/QuizCandidateRepository.php b/src/Repository/QuizCandidateRepository.php index 931ef82..cfb2c04 100644 --- a/src/Repository/QuizCandidateRepository.php +++ b/src/Repository/QuizCandidateRepository.php @@ -10,8 +10,10 @@ use Safe\DateTimeImmutable; use Tvdt\Entity\Candidate; use Tvdt\Entity\Quiz; use Tvdt\Entity\QuizCandidate; +use Tvdt\Tests\Repository\QuizCandidateRepositoryTest; -/** @extends ServiceEntityRepository */ +/** @extends ServiceEntityRepository + * @see QuizCandidateRepositoryTest */ class QuizCandidateRepository extends ServiceEntityRepository { public function __construct(ManagerRegistry $registry) diff --git a/src/Repository/QuizRepository.php b/src/Repository/QuizRepository.php index e4a2b5d..1c257f9 100644 --- a/src/Repository/QuizRepository.php +++ b/src/Repository/QuizRepository.php @@ -13,8 +13,10 @@ use Symfony\Component\Uid\Uuid; use Tvdt\Dto\Result; use Tvdt\Entity\Quiz; use Tvdt\Exception\ErrorClearingQuizException; +use Tvdt\Tests\Repository\QuizRepositoryTest; -/** @extends ServiceEntityRepository */ +/** @extends ServiceEntityRepository + * @see QuizRepositoryTest */ class QuizRepository extends ServiceEntityRepository { public function __construct(ManagerRegistry $registry, private readonly LoggerInterface $logger) diff --git a/src/Repository/SeasonRepository.php b/src/Repository/SeasonRepository.php index 88e3126..a7bae69 100644 --- a/src/Repository/SeasonRepository.php +++ b/src/Repository/SeasonRepository.php @@ -8,8 +8,10 @@ use Doctrine\Bundle\DoctrineBundle\Repository\ServiceEntityRepository; use Doctrine\Persistence\ManagerRegistry; use Tvdt\Entity\Season; use Tvdt\Entity\User; +use Tvdt\Tests\Repository\SeasonRepositoryTest; -/** @extends ServiceEntityRepository */ +/** @extends ServiceEntityRepository + * @see SeasonRepositoryTest */ class SeasonRepository extends ServiceEntityRepository { public function __construct(ManagerRegistry $registry) diff --git a/src/Repository/UserRepository.php b/src/Repository/UserRepository.php index afceb86..a3c4028 100644 --- a/src/Repository/UserRepository.php +++ b/src/Repository/UserRepository.php @@ -9,8 +9,10 @@ use Doctrine\Persistence\ManagerRegistry; use Symfony\Component\Security\Core\User\PasswordAuthenticatedUserInterface; use Symfony\Component\Security\Core\User\PasswordUpgraderInterface; use Tvdt\Entity\User; +use Tvdt\Tests\Repository\UserRepositoryTest; -/** @extends ServiceEntityRepository */ +/** @extends ServiceEntityRepository + * @see UserRepositoryTest */ class UserRepository extends ServiceEntityRepository implements PasswordUpgraderInterface { public function __construct(ManagerRegistry $registry) diff --git a/src/Security/Voter/SeasonVoter.php b/src/Security/Voter/SeasonVoter.php index 85fa9e2..d775c75 100644 --- a/src/Security/Voter/SeasonVoter.php +++ b/src/Security/Voter/SeasonVoter.php @@ -14,8 +14,10 @@ use Tvdt\Entity\Question; use Tvdt\Entity\Quiz; use Tvdt\Entity\Season; use Tvdt\Entity\User; +use Tvdt\Tests\Security\Voter\SeasonVoterTest; -/** @extends Voter */ +/** @extends Voter + * @see SeasonVoterTest */ final class SeasonVoter extends Voter { public const string EDIT = 'SEASON_EDIT';