From e3b3881baf43a593eda7445e333af8d2e5fa8481 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Ma=C3=ABl=20Gangloff?= Date: Wed, 22 Oct 2025 16:14:02 +0200 Subject: [PATCH] test: disable constructor when mocking RDAPService --- tests/Entity/DomainTest.php | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/tests/Entity/DomainTest.php b/tests/Entity/DomainTest.php index 6cc659f..d9e6788 100644 --- a/tests/Entity/DomainTest.php +++ b/tests/Entity/DomainTest.php @@ -10,9 +10,9 @@ use App\Entity\DomainStatus; use App\Exception\MalformedDomainException; use App\Service\RDAPService; use PHPUnit\Framework\Attributes\DataProvider; -use PHPUnit\Framework\TestCase; +use Symfony\Bundle\FrameworkBundle\Test\KernelTestCase; -final class DomainTest extends TestCase +final class DomainTest extends KernelTestCase { public function testIsRedemptionPeriod(): void { @@ -234,6 +234,7 @@ final class DomainTest extends TestCase bool $expected, ): void { $rdapServiceMock = $this->getMockBuilder(RDAPService::class) + ->disableOriginalConstructor() ->onlyMethods(['getExpiresInDays']) ->getMock();