From ebb101009c63f49614296df90235b26924255080 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Gr=C3=A9goire=20Paris?= Date: Thu, 28 Dec 2023 19:55:46 +0100 Subject: [PATCH] Remove inheritance Spotted while trying to merge https://github.com/doctrine/orm/pull/11076 (among other things) up into 3.0.x. On that branch, it is no longer possible for an entity to extend another entity without specifying an inheritance mapping type. I think the goal of that inheritance was just to reuse the identifier anyway, so let's just duplicate the identifier declaration instead. --- .../Ticket/GH11072/GH11072EntityAdvanced.php | 12 +++++++++++- 1 file changed, 11 insertions(+), 1 deletion(-) diff --git a/tests/Doctrine/Tests/ORM/Functional/Ticket/GH11072/GH11072EntityAdvanced.php b/tests/Doctrine/Tests/ORM/Functional/Ticket/GH11072/GH11072EntityAdvanced.php index 2495de40cf7..4ca0dd0ef7f 100644 --- a/tests/Doctrine/Tests/ORM/Functional/Ticket/GH11072/GH11072EntityAdvanced.php +++ b/tests/Doctrine/Tests/ORM/Functional/Ticket/GH11072/GH11072EntityAdvanced.php @@ -6,12 +6,22 @@ use Doctrine\ORM\Mapping\Column; use Doctrine\ORM\Mapping\Entity; +use Doctrine\ORM\Mapping\GeneratedValue; +use Doctrine\ORM\Mapping\Id; /** * @Entity */ -class GH11072EntityAdvanced extends GH11072EntityBasic +class GH11072EntityAdvanced { + /** + * @Id + * @Column(type="integer") + * @GeneratedValue + * @var int + */ + public $id; + /** @Column(type="json") */ public mixed $anything;