From 1ea2b5bc483622367a3bfbf60de2be972536cd9d Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Gabriel=20Ostroluck=C3=BD?= Date: Sun, 23 Jun 2024 16:50:29 +0200 Subject: [PATCH] Fix tests with newest doctrine/persistence --- tests/RegistryTest.php | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/tests/RegistryTest.php b/tests/RegistryTest.php index 9c4ff08e..b0ef211b 100644 --- a/tests/RegistryTest.php +++ b/tests/RegistryTest.php @@ -8,11 +8,11 @@ use Doctrine\Common\Annotations\AnnotationReader; use Doctrine\DBAL\Connection; use Doctrine\ORM\EntityManagerInterface; +use Doctrine\Persistence\ObjectManager; use Fixtures\Bundles\RepositoryServiceBundle\Entity\TestCustomClassRepoEntity; use Fixtures\Bundles\RepositoryServiceBundle\Repository\TestCustomClassRepoRepository; use InvalidArgumentException; use ProxyManager\Proxy\ProxyInterface; -use stdClass; use Symfony\Component\DependencyInjection\Container; use Symfony\Component\VarExporter\LazyObjectInterface; @@ -78,7 +78,7 @@ public function testGetConnectionNames(): void public function testGetDefaultEntityManager(): void { - $em = new stdClass(); + $em = $this->createMock(ObjectManager::class); $container = new Container(); $container->set('doctrine.orm.default_entity_manager', $em); @@ -89,7 +89,7 @@ public function testGetDefaultEntityManager(): void public function testGetEntityManager(): void { - $em = new stdClass(); + $em = $this->createMock(ObjectManager::class); $container = new Container(); $container->set('doctrine.orm.default_entity_manager', $em);