chore: upgrade phpunit to 12.5

This commit is contained in:
fromme committed 2026-10-01 10:07:05 +02:00
1 parent da039d0527
commit 849da8d471
53 files changed
+832 -856

No files matched your search

+8 -6
View File
@@ -13,6 +13,7 @@ use Doctrine\ORM\EntityManagerInterface;
use Doctrine\ORM\EntityRepository;
use Flagception\Manager\FeatureManagerInterface;
use League\OAuth2\Client\Token\AccessToken;
use PHPUnit\Framework\Attributes\AllowMockObjectsWithoutExpectations;
use PHPUnit\Framework\MockObject\MockObject;
use PHPUnit\Framework\TestCase;
use Psr\Log\LoggerInterface;
@@ -25,6 +26,7 @@ use Symfony\Component\Routing\Generator\UrlGeneratorInterface;
use Symfony\Component\Security\Core\Exception\CustomUserMessageAuthenticationException;
use Symfony\Component\Security\Http\Authenticator\Passport\Badge\UserBadge;
#[AllowMockObjectsWithoutExpectations]
class MyEpAuthenticatorTest extends TestCase
{
private EntityManagerInterface&MockObject $entityManager;
@@ -425,21 +427,21 @@ class MyEpAuthenticatorTest extends TestCase
private function createAuthenticator(array $userinfo, bool $featureActive = true, ?MockHttpClient $httpClient = null): MyEpAuthenticator
{
$client = $this->createMock(MyEpClient::class);
$client = $this->createStub(MyEpClient::class);
$client->method('fetchAccessToken')->willReturn(new AccessToken(['access_token' => 'token']));
$featureManager = $this->createMock(FeatureManagerInterface::class);
$featureManager = $this->createStub(FeatureManagerInterface::class);
$featureManager->method('isActive')->willReturn($featureActive);
return new MyEpAuthenticator(
$client,
$httpClient ?? $this->userinfoClient($userinfo),
new UserDataHandler($this->entityManager, $this->createMock(LoggerInterface::class)),
new UserDataHandler($this->entityManager, $this->createStub(LoggerInterface::class)),
$this->entityManager,
$this->createMock(UrlGeneratorInterface::class),
$this->createMock(LoggerInterface::class),
$this->createStub(UrlGeneratorInterface::class),
$this->createStub(LoggerInterface::class),
$featureManager,
$this->createMock(RequiredTeamerCheckRegistry::class),
$this->createStub(RequiredTeamerCheckRegistry::class),
);
}
}