diff --git a/tests/ResetPasswordTestKernel.php b/tests/ResetPasswordTestKernel.php index ccbae0a..601dbe0 100644 --- a/tests/ResetPasswordTestKernel.php +++ b/tests/ResetPasswordTestKernel.php @@ -87,16 +87,19 @@ public function registerContainerConfiguration(LoaderInterface $loader): void ], 'orm' => [ 'auto_generate_proxy_classes' => true, + 'controller_resolver' => ['auto_mapping' => false], // @see https://github.com/doctrine/DoctrineBundle/pull/1762 + 'enable_lazy_ghost_objects' => true, // @see https://github.com/doctrine/DoctrineBundle/pull/1733 'auto_mapping' => true, 'mappings' => [ 'App' => [ 'is_bundle' => false, - 'type' => self::shouldUseAttributes() ? 'attribute' : 'annotation', + 'type' => 'attribute', 'dir' => 'tests/Fixtures/Entity/', 'prefix' => 'SymfonyCasts\Bundle\ResetPassword\Tests\Fixtures\Entity', 'alias' => 'App', ], ], + 'report_fields_where_declared' => true, // @see https://github.com/doctrine/DoctrineBundle/pull/1661 ], ]); @@ -141,9 +144,4 @@ public function getLogDir(): string { return sys_get_temp_dir().'/logs'.spl_object_hash($this); } - - public static function shouldUseAttributes(): bool - { - return Kernel::VERSION_ID >= 70000; - } }