From 4d57797b9254e1bac52adb423800d42ed120a627 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Sun, 12 Oct 2025 15:24:42 +0000 Subject: [PATCH 01/14] Bump doctrine/.github from 8.0.0 to 10.1.0 Bumps [doctrine/.github](https://github.com/doctrine/.github) from 8.0.0 to 10.1.0. - [Release notes](https://github.com/doctrine/.github/releases) - [Commits](https://github.com/doctrine/.github/compare/8.0.0...10.1.0) --- updated-dependencies: - dependency-name: doctrine/.github dependency-version: 10.1.0 dependency-type: direct:production update-type: version-update:semver-major ... Signed-off-by: dependabot[bot] --- .github/workflows/coding-standards.yml | 2 +- .github/workflows/composer-lint.yml | 2 +- .github/workflows/documentation.yml | 2 +- .github/workflows/release-on-milestone-closed.yml | 2 +- .github/workflows/static-analysis.yml | 2 +- .github/workflows/website-schema.yml | 2 +- 6 files changed, 6 insertions(+), 6 deletions(-) diff --git a/.github/workflows/coding-standards.yml b/.github/workflows/coding-standards.yml index 52b7ea77..8273bad4 100644 --- a/.github/workflows/coding-standards.yml +++ b/.github/workflows/coding-standards.yml @@ -26,6 +26,6 @@ on: jobs: coding-standards: name: "Coding Standards" - uses: "doctrine/.github/.github/workflows/coding-standards.yml@8.0.0" + uses: "doctrine/.github/.github/workflows/coding-standards.yml@10.1.0" with: composer-options: "--prefer-dist --prefer-stable" diff --git a/.github/workflows/composer-lint.yml b/.github/workflows/composer-lint.yml index d679fb03..98c5f53b 100644 --- a/.github/workflows/composer-lint.yml +++ b/.github/workflows/composer-lint.yml @@ -17,4 +17,4 @@ on: jobs: composer-lint: name: "Composer Lint" - uses: "doctrine/.github/.github/workflows/composer-lint.yml@8.0.0" + uses: "doctrine/.github/.github/workflows/composer-lint.yml@10.1.0" diff --git a/.github/workflows/documentation.yml b/.github/workflows/documentation.yml index 1a6b1391..5b5e4f3e 100644 --- a/.github/workflows/documentation.yml +++ b/.github/workflows/documentation.yml @@ -17,4 +17,4 @@ on: jobs: documentation: name: "Documentation" - uses: "doctrine/.github/.github/workflows/documentation.yml@8.0.0" \ No newline at end of file + uses: "doctrine/.github/.github/workflows/documentation.yml@10.1.0" \ No newline at end of file diff --git a/.github/workflows/release-on-milestone-closed.yml b/.github/workflows/release-on-milestone-closed.yml index 29770e22..f6608016 100644 --- a/.github/workflows/release-on-milestone-closed.yml +++ b/.github/workflows/release-on-milestone-closed.yml @@ -8,7 +8,7 @@ on: jobs: release: name: "Git tag, release & create merge-up PR" - uses: "doctrine/.github/.github/workflows/release-on-milestone-closed.yml@8.0.0" + uses: "doctrine/.github/.github/workflows/release-on-milestone-closed.yml@10.1.0" secrets: GIT_AUTHOR_EMAIL: ${{ secrets.GIT_AUTHOR_EMAIL }} GIT_AUTHOR_NAME: ${{ secrets.GIT_AUTHOR_NAME }} diff --git a/.github/workflows/static-analysis.yml b/.github/workflows/static-analysis.yml index a951d95b..9d2550d8 100644 --- a/.github/workflows/static-analysis.yml +++ b/.github/workflows/static-analysis.yml @@ -26,4 +26,4 @@ on: jobs: static-analysis: name: "Static Analysis" - uses: "doctrine/.github/.github/workflows/phpstan.yml@8.0.0" + uses: "doctrine/.github/.github/workflows/phpstan.yml@10.1.0" diff --git a/.github/workflows/website-schema.yml b/.github/workflows/website-schema.yml index e7c8e15b..f249e6f3 100644 --- a/.github/workflows/website-schema.yml +++ b/.github/workflows/website-schema.yml @@ -18,4 +18,4 @@ on: jobs: json-validate: name: "Validate JSON schema" - uses: "doctrine/.github/.github/workflows/website-schema.yml@8.0.0" + uses: "doctrine/.github/.github/workflows/website-schema.yml@10.1.0" From 026694fc69c71e023150a26a0a3cd4e03cb53a89 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Gr=C3=A9goire=20Paris?= Date: Mon, 13 Oct 2025 20:24:28 +0200 Subject: [PATCH 02/14] Address PHPUnit notices They were all about using stubs rather than mocks when not adding any expectations. --- tests/Command/CreateDatabaseDoctrineTest.php | 12 +++++------- tests/Command/DropDatabaseDoctrineTest.php | 16 +++++++--------- .../DataCollector/DoctrineDataCollectorTest.php | 10 +++++----- .../Mapping/DisconnectedMetadataFactoryTest.php | 2 +- .../Middleware/IdleConnectionMiddlewareTest.php | 2 +- tests/ProfilerTest.php | 8 +++----- tests/RegistryTest.php | 8 ++++---- tests/Repository/ServiceEntityRepositoryTest.php | 4 ++-- 8 files changed, 28 insertions(+), 34 deletions(-) diff --git a/tests/Command/CreateDatabaseDoctrineTest.php b/tests/Command/CreateDatabaseDoctrineTest.php index 849c4e06..113ee347 100644 --- a/tests/Command/CreateDatabaseDoctrineTest.php +++ b/tests/Command/CreateDatabaseDoctrineTest.php @@ -11,7 +11,7 @@ use Doctrine\DBAL\DriverManager; use Doctrine\DBAL\Schema\SchemaManagerFactory; use Doctrine\Persistence\ManagerRegistry; -use PHPUnit\Framework\MockObject\MockObject; +use PHPUnit\Framework\MockObject\Stub; use PHPUnit\Framework\TestCase; use Symfony\Component\Console\Tester\CommandTester; use Symfony\Component\DependencyInjection\Container; @@ -59,25 +59,23 @@ public function testExecute(): void * @param mixed[]|null $params Connection parameters * @psalm-param Params $params * - * @return MockObject&Container + * @return Stub&Container */ - private function getMockContainer(string $connectionName, array|null $params = null): MockObject + private function getMockContainer(string $connectionName, array|null $params = null): Stub { // Mock the container and everything you'll need here $mockDoctrine = $this->createStub(ManagerRegistry::class); $mockDoctrine->method('getDefaultConnectionName')->willReturn($connectionName); - $config = (new Configuration())->setSchemaManagerFactory($this->createMock(SchemaManagerFactory::class)); + $config = (new Configuration())->setSchemaManagerFactory($this->createStub(SchemaManagerFactory::class)); $mockConnection = $this->createStub(Connection::class); $mockConnection->method('getConfiguration')->willReturn($config); $mockConnection->method('getParams')->willReturn($params); $mockDoctrine->method('getConnection')->willReturn($mockConnection); - $mockContainer = $this->getMockBuilder(Container::class) - ->onlyMethods(['get']) - ->getMock(); + $mockContainer = $this->createStub(Container::class); $mockContainer->method('get')->with('doctrine')->willReturn($mockDoctrine); diff --git a/tests/Command/DropDatabaseDoctrineTest.php b/tests/Command/DropDatabaseDoctrineTest.php index f7176499..c691867e 100644 --- a/tests/Command/DropDatabaseDoctrineTest.php +++ b/tests/Command/DropDatabaseDoctrineTest.php @@ -14,7 +14,7 @@ use Doctrine\Persistence\ManagerRegistry; use Generator; use PHPUnit\Framework\Attributes\DataProvider; -use PHPUnit\Framework\MockObject\MockObject; +use PHPUnit\Framework\MockObject\Stub; use PHPUnit\Framework\TestCase; use Symfony\Component\Console\Tester\CommandTester; use Symfony\Component\DependencyInjection\Container; @@ -137,9 +137,9 @@ public static function provideIncompatibleDriverOptions(): Generator * @param list $params Connection parameters * @psalm-param Params $params * - * @return MockObject&Container + * @return Stub&Container */ - private function getMockContainer(string $connectionName, array $params): MockObject + private function getMockContainer(string $connectionName, array $params): Stub { // Mock the container and everything you'll need here $mockDoctrine = $this->createStub(ManagerRegistry::class); @@ -148,18 +148,16 @@ private function getMockContainer(string $connectionName, array $params): MockOb $config = (new Configuration())->setSchemaManagerFactory(new DefaultSchemaManagerFactory()); - $mockConnection = $this->createMock(Connection::class); + $mockConnection = $this->createStub(Connection::class); $mockConnection->method('getConfiguration')->willReturn($config); $mockConnection->method('getParams')->willReturn($params); $mockDoctrine->method('getConnection')->willReturn($mockConnection); - $mockContainer = $this->getMockBuilder(Container::class) - ->onlyMethods(['get']) - ->getMock(); + $mockContainer = $this->createStub(Container::class); $mockContainer->method('get') - ->with('doctrine') - ->willReturn($mockDoctrine); + ->with('doctrine') + ->willReturn($mockDoctrine); return $mockContainer; } diff --git a/tests/DataCollector/DoctrineDataCollectorTest.php b/tests/DataCollector/DoctrineDataCollectorTest.php index 43a41d19..3112f1f4 100644 --- a/tests/DataCollector/DoctrineDataCollectorTest.php +++ b/tests/DataCollector/DoctrineDataCollectorTest.php @@ -35,8 +35,8 @@ public function testCollectEntities(): void $manager = $this->createStub(EntityManagerInterface::class); $config = $this->createMock(Configuration::class); $factory = $this->createMock(ClassMetadataFactory::class); - $collector = $this->createCollector(['default' => $manager], true, $this->createMock(DebugDataHolder::class)); - $unitOfWork = $this->createMock(UnitOfWork::class); + $collector = $this->createCollector(['default' => $manager], true, $this->createStub(DebugDataHolder::class)); + $unitOfWork = $this->createStub(UnitOfWork::class); $manager->method('getMetadataFactory')->willReturn($factory); $manager->method('getConfiguration')->willReturn($config); @@ -74,8 +74,8 @@ public function testDoesNotCollectEntities(): void } $manager = $this->createMock(EntityManager::class); - $config = $this->createMock(Configuration::class); - $collector = $this->createCollector(['default' => $manager], false, $this->createMock(DebugDataHolder::class)); + $config = $this->createStub(Configuration::class); + $collector = $this->createCollector(['default' => $manager], false, $this->createStub(DebugDataHolder::class)); $unitOfWork = $this->createStub(UnitOfWork::class); $manager->expects($this->never())->method('getMetadataFactory'); @@ -91,7 +91,7 @@ public function testDoesNotCollectEntities(): void public function testGetGroupedQueries(): void { - $debugDataHolder = $this->createMock(DebugDataHolder::class); + $debugDataHolder = $this->createStub(DebugDataHolder::class); $queries = [ 'default' => [ diff --git a/tests/Mapping/DisconnectedMetadataFactoryTest.php b/tests/Mapping/DisconnectedMetadataFactoryTest.php index 3c13605a..e6cb9d72 100644 --- a/tests/Mapping/DisconnectedMetadataFactoryTest.php +++ b/tests/Mapping/DisconnectedMetadataFactoryTest.php @@ -30,7 +30,7 @@ public function testCannotFindNamespaceAndPathForMetadata(): void $class = new ClassMetadata(self::class); $collection = new ClassMetadataCollection([$class]); - $registry = $this->getMockBuilder(ManagerRegistry::class)->getMock(); + $registry = $this->createStub(ManagerRegistry::class); $factory = new DisconnectedMetadataFactory($registry); $this->expectException(RuntimeException::class); diff --git a/tests/Middleware/IdleConnectionMiddlewareTest.php b/tests/Middleware/IdleConnectionMiddlewareTest.php index 25e64c0f..fc4b0d16 100644 --- a/tests/Middleware/IdleConnectionMiddlewareTest.php +++ b/tests/Middleware/IdleConnectionMiddlewareTest.php @@ -25,7 +25,7 @@ public function testWrap() $middleware = new IdleConnectionMiddleware($connectionExpiries, $ttlByConnection); $middleware->setConnectionName('connectionone'); - $driverMock = $this->createMock(Driver::class); + $driverMock = $this->createStub(Driver::class); $wrappedDriver = $middleware->wrap($driverMock); $this->assertInstanceOf(IdleConnectionDriver::class, $wrappedDriver); diff --git a/tests/ProfilerTest.php b/tests/ProfilerTest.php index 3e9e3031..ae2cbcad 100644 --- a/tests/ProfilerTest.php +++ b/tests/ProfilerTest.php @@ -43,7 +43,7 @@ class ProfilerTest extends BaseTestCase public function setUp(): void { $this->debugDataHolder = new DebugDataHolder(); - $registry = $this->getMockBuilder(ManagerRegistry::class)->getMock(); + $registry = $this->createStub(ManagerRegistry::class); $registry->method('getConnectionNames')->willReturn([]); $registry->method('getManagerNames')->willReturn([]); $registry->method('getManagers')->willReturn([]); @@ -53,14 +53,12 @@ public function setUp(): void $twigLoaderFilesystem->addPath(__DIR__ . '/../vendor/symfony/web-profiler-bundle/Resources/views', 'WebProfiler'); $this->twig = new Environment($twigLoaderFilesystem, ['debug' => true, 'strict_variables' => true]); - $fragmentHandler = $this->getMockBuilder(FragmentHandler::class); - $fragmentHandler->disableOriginalConstructor(); - $fragmentHandler = $fragmentHandler->getMock(); + $fragmentHandler = $this->createStub(FragmentHandler::class); $fragmentHandler->method('render')->willReturn(''); $kernelRuntime = new HttpKernelRuntime($fragmentHandler); - $urlGenerator = $this->getMockBuilder(UrlGeneratorInterface::class)->getMock(); + $urlGenerator = $this->createStub(UrlGeneratorInterface::class); $urlGenerator->method('generate')->willReturn(''); if (class_exists(CodeExtension::class)) { diff --git a/tests/RegistryTest.php b/tests/RegistryTest.php index 59ee8098..72841941 100644 --- a/tests/RegistryTest.php +++ b/tests/RegistryTest.php @@ -43,7 +43,7 @@ public function testGetDefaultEntityManagerName(): void public function testGetDefaultConnection(): void { - $conn = $this->getMockBuilder(Connection::class)->disableOriginalConstructor()->getMock(); + $conn = $this->createStub(Connection::class); $container = new Container(); $container->set('doctrine.dbal.default_connection', $conn); @@ -54,7 +54,7 @@ public function testGetDefaultConnection(): void public function testGetConnection(): void { - $conn = $this->getMockBuilder(Connection::class)->disableOriginalConstructor()->getMock(); + $conn = $this->createStub(Connection::class); $container = new Container(); $container->set('doctrine.dbal.default_connection', $conn); @@ -81,7 +81,7 @@ public function testGetConnectionNames(): void public function testGetDefaultEntityManager(): void { - $em = $this->createMock(ObjectManager::class); + $em = $this->createStub(ObjectManager::class); $container = new Container(); $container->set('doctrine.orm.default_entity_manager', $em); @@ -92,7 +92,7 @@ public function testGetDefaultEntityManager(): void public function testGetEntityManager(): void { - $em = $this->createMock(ObjectManager::class); + $em = $this->createStub(ObjectManager::class); $container = new Container(); $container->set('doctrine.orm.default_entity_manager', $em); diff --git a/tests/Repository/ServiceEntityRepositoryTest.php b/tests/Repository/ServiceEntityRepositoryTest.php index b39188c4..43ca68d4 100644 --- a/tests/Repository/ServiceEntityRepositoryTest.php +++ b/tests/Repository/ServiceEntityRepositoryTest.php @@ -31,7 +31,7 @@ public static function setUpBeforeClass(): void public function testConstructorThrowsExceptionWhenNoManagerFound(): void { - $registry = $this->getMockBuilder(ManagerRegistry::class)->getMock(); + $registry = $this->createStub(ManagerRegistry::class); $this->expectException(LogicException::class); $this->expectExceptionMessage(<<<'EXCEPTION' Could not find the entity manager for class "Doctrine\Bundle\DoctrineBundle\Tests\Repository\TestEntity". Check your Doctrine configuration to make sure it is configured to load this entity’s metadata. @@ -46,7 +46,7 @@ public function testConstructorThrowsExceptionWhenNoManagerFound(): void #[RequiresPhp('>= 8.4')] public function testConstructInitializesWhenImplementingLazyObjectInterface(): void { - $registry = $this->getMockBuilder(ManagerRegistry::class)->getMock(); + $registry = $this->createStub(ManagerRegistry::class); $this->expectException(LogicException::class); /* @phpstan-ignore class.notFound, expr.resultUnused */ From 5df4d430c1d318d028963184e0c171525b207548 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Gr=C3=A9goire=20Paris?= Date: Tue, 14 Oct 2025 20:10:02 +0200 Subject: [PATCH 03/14] Update validate_xml_mapping info The mentioned validation did not become mandatory in ORM 3.0, you can still opt out. --- src/DependencyInjection/Configuration.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/DependencyInjection/Configuration.php b/src/DependencyInjection/Configuration.php index bf402bf1..196c8e94 100644 --- a/src/DependencyInjection/Configuration.php +++ b/src/DependencyInjection/Configuration.php @@ -714,7 +714,7 @@ private function getOrmEntityManagersNode(): ArrayNodeDefinition ->thenInvalid('The setting "report_fields_where_declared" cannot be disabled for ORM 3.') ->end() ->end() - ->booleanNode('validate_xml_mapping')->defaultFalse()->info('Set to "true" to opt-in to the new mapping driver mode that was added in Doctrine ORM 2.14 and will be mandatory in ORM 3.0. See https://github.com/doctrine/orm/pull/6728.')->end() + ->booleanNode('validate_xml_mapping')->defaultFalse()->info('Set to "true" to opt-in to the new mapping driver mode that was added in Doctrine ORM 2.14. See https://github.com/doctrine/orm/pull/6728.')->end() ->end() ->children() ->arrayNode('second_level_cache') From d088386bb0f9f0544f321b201ac31605b27e783e Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 20 Oct 2025 15:42:25 +0000 Subject: [PATCH 04/14] Bump doctrine/.github from 10.1.0 to 12.0.0 Bumps [doctrine/.github](https://github.com/doctrine/.github) from 10.1.0 to 12.0.0. - [Release notes](https://github.com/doctrine/.github/releases) - [Commits](https://github.com/doctrine/.github/compare/10.1.0...12.0.0) --- updated-dependencies: - dependency-name: doctrine/.github dependency-version: 12.0.0 dependency-type: direct:production update-type: version-update:semver-major ... Signed-off-by: dependabot[bot] --- .github/workflows/coding-standards.yml | 2 +- .github/workflows/composer-lint.yml | 2 +- .github/workflows/documentation.yml | 2 +- .github/workflows/release-on-milestone-closed.yml | 2 +- .github/workflows/static-analysis.yml | 2 +- .github/workflows/website-schema.yml | 2 +- docs/composer.json | 8 ++++++++ 7 files changed, 14 insertions(+), 6 deletions(-) create mode 100644 docs/composer.json diff --git a/.github/workflows/coding-standards.yml b/.github/workflows/coding-standards.yml index 8273bad4..f10fb8f9 100644 --- a/.github/workflows/coding-standards.yml +++ b/.github/workflows/coding-standards.yml @@ -26,6 +26,6 @@ on: jobs: coding-standards: name: "Coding Standards" - uses: "doctrine/.github/.github/workflows/coding-standards.yml@10.1.0" + uses: "doctrine/.github/.github/workflows/coding-standards.yml@12.0.0" with: composer-options: "--prefer-dist --prefer-stable" diff --git a/.github/workflows/composer-lint.yml b/.github/workflows/composer-lint.yml index 98c5f53b..de581eeb 100644 --- a/.github/workflows/composer-lint.yml +++ b/.github/workflows/composer-lint.yml @@ -17,4 +17,4 @@ on: jobs: composer-lint: name: "Composer Lint" - uses: "doctrine/.github/.github/workflows/composer-lint.yml@10.1.0" + uses: "doctrine/.github/.github/workflows/composer-lint.yml@12.0.0" diff --git a/.github/workflows/documentation.yml b/.github/workflows/documentation.yml index 5b5e4f3e..1a61c452 100644 --- a/.github/workflows/documentation.yml +++ b/.github/workflows/documentation.yml @@ -17,4 +17,4 @@ on: jobs: documentation: name: "Documentation" - uses: "doctrine/.github/.github/workflows/documentation.yml@10.1.0" \ No newline at end of file + uses: "doctrine/.github/.github/workflows/documentation.yml@12.0.0" \ No newline at end of file diff --git a/.github/workflows/release-on-milestone-closed.yml b/.github/workflows/release-on-milestone-closed.yml index f6608016..329e5571 100644 --- a/.github/workflows/release-on-milestone-closed.yml +++ b/.github/workflows/release-on-milestone-closed.yml @@ -8,7 +8,7 @@ on: jobs: release: name: "Git tag, release & create merge-up PR" - uses: "doctrine/.github/.github/workflows/release-on-milestone-closed.yml@10.1.0" + uses: "doctrine/.github/.github/workflows/release-on-milestone-closed.yml@12.0.0" secrets: GIT_AUTHOR_EMAIL: ${{ secrets.GIT_AUTHOR_EMAIL }} GIT_AUTHOR_NAME: ${{ secrets.GIT_AUTHOR_NAME }} diff --git a/.github/workflows/static-analysis.yml b/.github/workflows/static-analysis.yml index 9d2550d8..401da3e2 100644 --- a/.github/workflows/static-analysis.yml +++ b/.github/workflows/static-analysis.yml @@ -26,4 +26,4 @@ on: jobs: static-analysis: name: "Static Analysis" - uses: "doctrine/.github/.github/workflows/phpstan.yml@10.1.0" + uses: "doctrine/.github/.github/workflows/phpstan.yml@12.0.0" diff --git a/.github/workflows/website-schema.yml b/.github/workflows/website-schema.yml index f249e6f3..66202e20 100644 --- a/.github/workflows/website-schema.yml +++ b/.github/workflows/website-schema.yml @@ -18,4 +18,4 @@ on: jobs: json-validate: name: "Validate JSON schema" - uses: "doctrine/.github/.github/workflows/website-schema.yml@10.1.0" + uses: "doctrine/.github/.github/workflows/website-schema.yml@12.0.0" diff --git a/docs/composer.json b/docs/composer.json new file mode 100644 index 00000000..5072d501 --- /dev/null +++ b/docs/composer.json @@ -0,0 +1,8 @@ +{ + "require-dev": { + "doctrine/docs-builder": "^1.0" + }, + "config": { + "sort-packages": true + } +} From 862f667272dfc8718d573cfeaa1cb0198e1aae80 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 27 Oct 2025 16:24:18 +0000 Subject: [PATCH 05/14] Bump doctrine/.github from 12.0.0 to 12.1.0 Bumps [doctrine/.github](https://github.com/doctrine/.github) from 12.0.0 to 12.1.0. - [Release notes](https://github.com/doctrine/.github/releases) - [Commits](https://github.com/doctrine/.github/compare/12.0.0...12.1.0) --- updated-dependencies: - dependency-name: doctrine/.github dependency-version: 12.1.0 dependency-type: direct:production update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] --- .github/workflows/coding-standards.yml | 2 +- .github/workflows/composer-lint.yml | 2 +- .github/workflows/documentation.yml | 2 +- .github/workflows/release-on-milestone-closed.yml | 2 +- .github/workflows/static-analysis.yml | 2 +- .github/workflows/website-schema.yml | 2 +- 6 files changed, 6 insertions(+), 6 deletions(-) diff --git a/.github/workflows/coding-standards.yml b/.github/workflows/coding-standards.yml index f10fb8f9..0f6dc856 100644 --- a/.github/workflows/coding-standards.yml +++ b/.github/workflows/coding-standards.yml @@ -26,6 +26,6 @@ on: jobs: coding-standards: name: "Coding Standards" - uses: "doctrine/.github/.github/workflows/coding-standards.yml@12.0.0" + uses: "doctrine/.github/.github/workflows/coding-standards.yml@12.1.0" with: composer-options: "--prefer-dist --prefer-stable" diff --git a/.github/workflows/composer-lint.yml b/.github/workflows/composer-lint.yml index de581eeb..4b296926 100644 --- a/.github/workflows/composer-lint.yml +++ b/.github/workflows/composer-lint.yml @@ -17,4 +17,4 @@ on: jobs: composer-lint: name: "Composer Lint" - uses: "doctrine/.github/.github/workflows/composer-lint.yml@12.0.0" + uses: "doctrine/.github/.github/workflows/composer-lint.yml@12.1.0" diff --git a/.github/workflows/documentation.yml b/.github/workflows/documentation.yml index 1a61c452..93fd4c65 100644 --- a/.github/workflows/documentation.yml +++ b/.github/workflows/documentation.yml @@ -17,4 +17,4 @@ on: jobs: documentation: name: "Documentation" - uses: "doctrine/.github/.github/workflows/documentation.yml@12.0.0" \ No newline at end of file + uses: "doctrine/.github/.github/workflows/documentation.yml@12.1.0" \ No newline at end of file diff --git a/.github/workflows/release-on-milestone-closed.yml b/.github/workflows/release-on-milestone-closed.yml index 329e5571..89dba39e 100644 --- a/.github/workflows/release-on-milestone-closed.yml +++ b/.github/workflows/release-on-milestone-closed.yml @@ -8,7 +8,7 @@ on: jobs: release: name: "Git tag, release & create merge-up PR" - uses: "doctrine/.github/.github/workflows/release-on-milestone-closed.yml@12.0.0" + uses: "doctrine/.github/.github/workflows/release-on-milestone-closed.yml@12.1.0" secrets: GIT_AUTHOR_EMAIL: ${{ secrets.GIT_AUTHOR_EMAIL }} GIT_AUTHOR_NAME: ${{ secrets.GIT_AUTHOR_NAME }} diff --git a/.github/workflows/static-analysis.yml b/.github/workflows/static-analysis.yml index 401da3e2..2f0ce4cc 100644 --- a/.github/workflows/static-analysis.yml +++ b/.github/workflows/static-analysis.yml @@ -26,4 +26,4 @@ on: jobs: static-analysis: name: "Static Analysis" - uses: "doctrine/.github/.github/workflows/phpstan.yml@12.0.0" + uses: "doctrine/.github/.github/workflows/phpstan.yml@12.1.0" diff --git a/.github/workflows/website-schema.yml b/.github/workflows/website-schema.yml index 66202e20..f56b7241 100644 --- a/.github/workflows/website-schema.yml +++ b/.github/workflows/website-schema.yml @@ -18,4 +18,4 @@ on: jobs: json-validate: name: "Validate JSON schema" - uses: "doctrine/.github/.github/workflows/website-schema.yml@12.0.0" + uses: "doctrine/.github/.github/workflows/website-schema.yml@12.1.0" From f9ab2d730de656f939312795963f3f1f4f46c85e Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Gr=C3=A9goire=20Paris?= Date: Sat, 1 Nov 2025 21:03:50 +0100 Subject: [PATCH 06/14] Revert "Scan file where DI functions are defined" This reverts commit 5abeb296ba07f1493ad1de945329aba74fd8e654. The scanned file no longer exists since https://github.com/symfony/symfony/pull/62129, which aims precisely at making the scan unnecessary (among other things). --- phpstan.neon.dist | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/phpstan.neon.dist b/phpstan.neon.dist index 3f779671..0b3cc38b 100644 --- a/phpstan.neon.dist +++ b/phpstan.neon.dist @@ -4,8 +4,7 @@ parameters: - config - src - tests - scanFiles: - - vendor/symfony/dependency-injection/Loader/Configurator/functions.php + excludePaths: - src/Command/Proxy/ConvertMappingDoctrineCommand.php - src/Command/Proxy/EnsureProductionSettingsDoctrineCommand.php From ec96d28d155475d4f59861ab8773f2413c49d2d0 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Gr=C3=A9goire=20Paris?= Date: Sat, 1 Nov 2025 21:12:48 +0100 Subject: [PATCH 07/14] Configure new kernel parameters They appear to be mandatory. --- tests/CacheSchemaSubscriberTest.php | 2 ++ tests/DependencyInjection/Compiler/IdGeneratorPassTest.php | 2 ++ tests/LockStoreSchemaListenerTest.php | 2 ++ tests/ServiceRepositoryTest.php | 2 ++ 4 files changed, 8 insertions(+) diff --git a/tests/CacheSchemaSubscriberTest.php b/tests/CacheSchemaSubscriberTest.php index 3c4d4df6..96d825b0 100644 --- a/tests/CacheSchemaSubscriberTest.php +++ b/tests/CacheSchemaSubscriberTest.php @@ -32,8 +32,10 @@ public function testSchemaSubscriberWiring(): void 'kernel.build_dir' => sys_get_temp_dir(), 'kernel.environment' => 'test', 'kernel.runtime_environment' => '%%env(default:kernel.environment:APP_RUNTIME_ENV)%%', + 'kernel.runtime_mode.web' => false, 'kernel.root_dir' => __DIR__ . '/../../../../', // src dir 'kernel.project_dir' => __DIR__ . '/../../../../', // src dir + 'kernel.share_dir' => sys_get_temp_dir(), 'kernel.bundles_metadata' => [], 'kernel.charset' => 'UTF-8', 'kernel.container_class' => ContainerBuilder::class, diff --git a/tests/DependencyInjection/Compiler/IdGeneratorPassTest.php b/tests/DependencyInjection/Compiler/IdGeneratorPassTest.php index 14177f5f..9f40c8e1 100644 --- a/tests/DependencyInjection/Compiler/IdGeneratorPassTest.php +++ b/tests/DependencyInjection/Compiler/IdGeneratorPassTest.php @@ -50,8 +50,10 @@ public function testRepositoryServiceWiring(): void 'kernel.bundles' => $bundles, 'kernel.cache_dir' => sys_get_temp_dir(), 'kernel.build_dir' => sys_get_temp_dir(), + 'kernel.share_dir' => sys_get_temp_dir(), 'kernel.environment' => 'test', 'kernel.runtime_environment' => '%%env(default:kernel.environment:APP_RUNTIME_ENV)%%', + 'kernel.runtime_mode.web' => false, 'kernel.root_dir' => __DIR__ . '/../../../../', // src dir 'kernel.project_dir' => __DIR__ . '/../../../../', // src dir 'kernel.bundles_metadata' => [], diff --git a/tests/LockStoreSchemaListenerTest.php b/tests/LockStoreSchemaListenerTest.php index 5e4db9fc..27f7f6e7 100644 --- a/tests/LockStoreSchemaListenerTest.php +++ b/tests/LockStoreSchemaListenerTest.php @@ -31,8 +31,10 @@ public function testLockStoreSchemaSubscriberWiring(array $config, int $expected 'kernel.bundles' => [], 'kernel.cache_dir' => sys_get_temp_dir(), 'kernel.build_dir' => sys_get_temp_dir(), + 'kernel.share_dir' => sys_get_temp_dir(), 'kernel.environment' => 'test', 'kernel.runtime_environment' => '%%env(default:kernel.environment:APP_RUNTIME_ENV)%%', + 'kernel.runtime_mode.web' => false, 'kernel.root_dir' => __DIR__ . '/../../../../', // src dir 'kernel.project_dir' => __DIR__ . '/../../../../', // src dir 'kernel.bundles_metadata' => [], diff --git a/tests/ServiceRepositoryTest.php b/tests/ServiceRepositoryTest.php index f60d2660..318efddc 100644 --- a/tests/ServiceRepositoryTest.php +++ b/tests/ServiceRepositoryTest.php @@ -48,8 +48,10 @@ public function testRepositoryServiceWiring(): void 'kernel.build_dir' => sys_get_temp_dir(), 'kernel.environment' => 'test', 'kernel.runtime_environment' => '%%env(default:kernel.environment:APP_RUNTIME_ENV)%%', + 'kernel.runtime_mode.web' => false, 'kernel.root_dir' => __DIR__ . '/../../../../', // src dir 'kernel.project_dir' => __DIR__ . '/../../../../', // src dir + 'kernel.share_dir' => sys_get_temp_dir(), 'kernel.bundles_metadata' => [], 'kernel.charset' => 'UTF-8', 'kernel.container_class' => ContainerBuilder::class, From 0da556b4512b161141629d2333859bc66c2b5290 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Sun, 2 Nov 2025 12:32:16 +0000 Subject: [PATCH 08/14] Bump actions/download-artifact from 5 to 6 Bumps [actions/download-artifact](https://github.com/actions/download-artifact) from 5 to 6. - [Release notes](https://github.com/actions/download-artifact/releases) - [Commits](https://github.com/actions/download-artifact/compare/v5...v6) --- updated-dependencies: - dependency-name: actions/download-artifact dependency-version: '6' dependency-type: direct:production update-type: version-update:semver-major ... Signed-off-by: dependabot[bot] --- .github/workflows/continuous-integration.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/continuous-integration.yml b/.github/workflows/continuous-integration.yml index 63a89fe5..7166737a 100644 --- a/.github/workflows/continuous-integration.yml +++ b/.github/workflows/continuous-integration.yml @@ -135,7 +135,7 @@ jobs: fetch-depth: 2 - name: "Download coverage files" - uses: "actions/download-artifact@v5" + uses: "actions/download-artifact@v6" with: path: "reports" From 011ec6bd0d7fb1b8dcca70fc798387f0a38c809a Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Sun, 2 Nov 2025 12:32:27 +0000 Subject: [PATCH 09/14] Bump actions/upload-artifact from 4 to 5 Bumps [actions/upload-artifact](https://github.com/actions/upload-artifact) from 4 to 5. - [Release notes](https://github.com/actions/upload-artifact/releases) - [Commits](https://github.com/actions/upload-artifact/compare/v4...v5) --- updated-dependencies: - dependency-name: actions/upload-artifact dependency-version: '5' dependency-type: direct:production update-type: version-update:semver-major ... Signed-off-by: dependabot[bot] --- .github/workflows/continuous-integration.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/continuous-integration.yml b/.github/workflows/continuous-integration.yml index 63a89fe5..21d443ed 100644 --- a/.github/workflows/continuous-integration.yml +++ b/.github/workflows/continuous-integration.yml @@ -115,7 +115,7 @@ jobs: run: "vendor/bin/phpunit --coverage-clover=coverage.xml" - name: "Upload coverage file" - uses: "actions/upload-artifact@v4" + uses: "actions/upload-artifact@v5" with: name: "phpunit-${{ matrix.php-version }}-${{ matrix.dependencies }}-${{ hashFiles('composer.lock') }}.coverage" path: "coverage.xml" From 17b0d1ad44162dacf4460880233962ef14551332 Mon Sep 17 00:00:00 2001 From: Julien Tattevin Date: Thu, 16 Oct 2025 17:53:55 +0200 Subject: [PATCH 10/14] Fix detectMappingType if the entity contain a package attribute --- src/DependencyInjection/DoctrineExtension.php | 4 +- .../DoctrineExtensionTest.php | 42 +++++++++++++++++++ .../AnnotationsBundle/AnnotationsBundle.php | 11 +++++ .../Entity/TestAnnotationEntity.php | 16 +++++++ .../AttributesWithPackageBundle.php | 11 +++++ .../Entity/TestInterface.php | 10 +++++ 6 files changed, 92 insertions(+), 2 deletions(-) create mode 100644 tests/DependencyInjection/Fixtures/Bundles/AnnotationsBundle/AnnotationsBundle.php create mode 100644 tests/DependencyInjection/Fixtures/Bundles/AnnotationsBundle/Entity/TestAnnotationEntity.php create mode 100644 tests/DependencyInjection/Fixtures/Bundles/AttributesWithPackageBundle/AttributesWithPackageBundle.php create mode 100644 tests/DependencyInjection/Fixtures/Bundles/AttributesWithPackageBundle/Entity/TestInterface.php diff --git a/src/DependencyInjection/DoctrineExtension.php b/src/DependencyInjection/DoctrineExtension.php index 6a461a90..63da7d06 100644 --- a/src/DependencyInjection/DoctrineExtension.php +++ b/src/DependencyInjection/DoctrineExtension.php @@ -427,8 +427,8 @@ private function detectMappingType(string $directory, ContainerBuilder $containe } if ( - preg_match('/^(?: \*|\/\*\*) @.*' . $quotedMappingObjectName . '\b/m', $content) - || preg_match('/^(?: \*|\/\*\*) @.*Embeddable\b/m', $content) + preg_match('/^(?: \*|\/\*\*) @[a-zA-Z\\\\]*' . $quotedMappingObjectName . '\b/m', $content) + || preg_match('/^(?: \*|\/\*\*) @[a-zA-Z\\\\]*Embeddable\b/m', $content) ) { $type = 'annotation'; break; diff --git a/tests/DependencyInjection/DoctrineExtensionTest.php b/tests/DependencyInjection/DoctrineExtensionTest.php index 3fd421fd..35e763f1 100644 --- a/tests/DependencyInjection/DoctrineExtensionTest.php +++ b/tests/DependencyInjection/DoctrineExtensionTest.php @@ -1507,6 +1507,48 @@ public function testControllerResolver(bool $simpleEntityManagerConfig): void $this->assertEquals(new MapEntity(null, null, null, [], null, null, null, true, true), $container->get('controller_resolver_defaults')); } + #[TestWith(['AnnotationsBundle', 'attribute', 'Vendor'], 'Bundle without anything')] + #[TestWith(['AttributesBundle', 'attribute'], 'Bundle with attributes')] + #[TestWith(['RepositoryServiceBundle', 'attribute'], 'Bundle with both')] + #[TestWith(['AnnotationsBundle', 'annotation'], 'Bundle with annotations')] + #[TestWith(['AttributesWithPackageBundle', 'attribute'], 'Bundle with attributes and @package')] + public function testDetectMappingType(string $bundle, string $expectedType, string $vendor = '') + { + if (! interface_exists(EntityManagerInterface::class)) { + self::markTestSkipped('This test requires ORM'); + } + + $container = $this->getContainer([$bundle], $vendor); + $extension = new DoctrineExtension(); + + $config = BundleConfigurationBuilder::createBuilder() + ->addBaseConnection() + ->addEntityManager([ + 'default_entity_manager' => 'default', + 'entity_managers' => [ + 'default' => [ + 'mappings' => [ + $bundle => [], + ], + ], + ], + ]) + ->build(); + + if (! class_exists(AnnotationDriver::class) && $expectedType === 'annotation') { + $this->expectException(LogicException::class); + $this->expectExceptionMessage('The annotation driver is only available in doctrine/orm v2.'); + } + + $extension->load([$config], $container); + + $calls = $container->getDefinition('doctrine.orm.default_metadata_driver')->getMethodCalls(); + $this->assertEquals( + sprintf('doctrine.orm.default_%s_metadata_driver', $expectedType), + (string) $calls[0][1][0], + ); + } + /** @param list $bundles */ private static function getContainer(array $bundles = ['XmlBundle'], string $vendor = ''): ContainerBuilder { diff --git a/tests/DependencyInjection/Fixtures/Bundles/AnnotationsBundle/AnnotationsBundle.php b/tests/DependencyInjection/Fixtures/Bundles/AnnotationsBundle/AnnotationsBundle.php new file mode 100644 index 00000000..27f39527 --- /dev/null +++ b/tests/DependencyInjection/Fixtures/Bundles/AnnotationsBundle/AnnotationsBundle.php @@ -0,0 +1,11 @@ + Date: Thu, 16 Oct 2025 18:41:05 +0200 Subject: [PATCH 11/14] Fix regex to match php allowed char in namespace --- src/DependencyInjection/DoctrineExtension.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/DependencyInjection/DoctrineExtension.php b/src/DependencyInjection/DoctrineExtension.php index 63da7d06..ab480988 100644 --- a/src/DependencyInjection/DoctrineExtension.php +++ b/src/DependencyInjection/DoctrineExtension.php @@ -427,8 +427,8 @@ private function detectMappingType(string $directory, ContainerBuilder $containe } if ( - preg_match('/^(?: \*|\/\*\*) @[a-zA-Z\\\\]*' . $quotedMappingObjectName . '\b/m', $content) - || preg_match('/^(?: \*|\/\*\*) @[a-zA-Z\\\\]*Embeddable\b/m', $content) + preg_match('/^(?: \*|\/\*\*) @\\\\?([a-zA-Z_\x80-\xff][a-zA-Z0-9_\x80-\xff]*\\\\?)*' . $quotedMappingObjectName . '\b/m', $content) + || preg_match('/^(?: \*|\/\*\*) @\\\\?([a-zA-Z_\x80-\xff][a-zA-Z0-9_\x80-\xff]*\\\\?)*Embeddable\b/m', $content) ) { $type = 'annotation'; break; From f4a9935af5713bbd3dbac465fdabeb5a79abf743 Mon Sep 17 00:00:00 2001 From: Julien Tattevin Date: Mon, 20 Oct 2025 12:36:05 +0200 Subject: [PATCH 12/14] Add tests and comments on the regex --- src/DependencyInjection/DoctrineExtension.php | 19 +++++++++++++++-- .../DoctrineExtensionTest.php | 21 +++++++++++++++++++ 2 files changed, 38 insertions(+), 2 deletions(-) diff --git a/src/DependencyInjection/DoctrineExtension.php b/src/DependencyInjection/DoctrineExtension.php index ab480988..3a976bdc 100644 --- a/src/DependencyInjection/DoctrineExtension.php +++ b/src/DependencyInjection/DoctrineExtension.php @@ -427,8 +427,8 @@ private function detectMappingType(string $directory, ContainerBuilder $containe } if ( - preg_match('/^(?: \*|\/\*\*) @\\\\?([a-zA-Z_\x80-\xff][a-zA-Z0-9_\x80-\xff]*\\\\?)*' . $quotedMappingObjectName . '\b/m', $content) - || preg_match('/^(?: \*|\/\*\*) @\\\\?([a-zA-Z_\x80-\xff][a-zA-Z0-9_\x80-\xff]*\\\\?)*Embeddable\b/m', $content) + self::textContainsAnnotation($quotedMappingObjectName, $content) + || self::textContainsAnnotation('Embeddable', $content) ) { $type = 'annotation'; break; @@ -438,6 +438,21 @@ private function detectMappingType(string $directory, ContainerBuilder $containe return $type; } + /** + * Check if the file content contains a class-like annotation + * + * @internal + */ + public static function textContainsAnnotation(string $quotedMappingObjectName, string $content): bool + { + return preg_match('/^(?:[ ]\*|\/\*\*)[ ]@ # Match phpdoc start or line with an at + \\\\? # Can start with antislash + ([a-zA-Z_\x80-\xff][a-zA-Z0-9_\x80-\xff]*\\\\?)* # Match 0-n namespace, the antislash is optionnal as it may be a prefix if an alias is used + ' . $quotedMappingObjectName . ' # The target class + [a-zA-Z0-9_\x80-\xff]* # Match a suffix if the class is aliased + \b/mx', $content) === 1; + } + /** * Returns a modified version of $managerConfigs. * diff --git a/tests/DependencyInjection/DoctrineExtensionTest.php b/tests/DependencyInjection/DoctrineExtensionTest.php index 35e763f1..8d3bbe31 100644 --- a/tests/DependencyInjection/DoctrineExtensionTest.php +++ b/tests/DependencyInjection/DoctrineExtensionTest.php @@ -1549,6 +1549,27 @@ public function testDetectMappingType(string $bundle, string $expectedType, stri ); } + #[TestWith([' * @Mapping\\Entity', true], 'Using the namespace without alias')] + #[TestWith([' * @ORM\\Entity', true], 'Using the namespace with alias')] + #[TestWith([' * @\\Doctrine\\ORM\\Mapping\\Entity', true], 'Complete namespace with starting slash')] + #[TestWith([' * @Doctrine\\ORM\\Mapping\\Entity', true], 'Complete namespace without starting slash')] + #[TestWith([' * @Entity', true], 'Use of the class')] + #[TestWith(['/** @Entity */', true], 'Comment start')] + #[TestWith([' * @ORMEntity', true], 'Use of the class with alias prefixing')] + #[TestWith([' * @EntityORM', true], 'Use of the class with alias suffixing')] + #[TestWith([' * @ormEntity', true], 'namespace can start with lowercase')] + #[TestWith([' * @_ORMEntity', true], 'namespace can start with underscore')] + #[TestWith([" * @\x80ORMEntity", true], 'namespace can start with char from x80-Xff')] + #[TestWith([" * @orm0_\x80Entity", true], 'namespace can contain number, underscore and char from x80-Xff')] + #[TestWith([' * @package testEntity', false], 'Annotation with Entity as value')] + #[TestWith([' * @entity', false], 'Lowercase use of the class')] + #[TestWith([' * @1ORMEntity', false], 'namespace can\'t start with number')] + #[TestWith([' * @extend', false], 'The Entity is used inside < and >')] + public function testTextContainsAnnotation(string $input, bool $expected): void + { + self::assertEquals($expected, DoctrineExtension::textContainsAnnotation('Entity', $input)); + } + /** @param list $bundles */ private static function getContainer(array $bundles = ['XmlBundle'], string $vendor = ''): ContainerBuilder { From 126ec9e00b582dba78a7ea99476c56cce5acf1ec Mon Sep 17 00:00:00 2001 From: Julien Tattevin Date: Mon, 20 Oct 2025 16:48:27 +0200 Subject: [PATCH 13/14] Remove prefix/suffix detection ; Adjust comments --- src/DependencyInjection/DoctrineExtension.php | 8 ++++---- .../DependencyInjection/DoctrineExtensionTest.php | 14 ++++++++------ 2 files changed, 12 insertions(+), 10 deletions(-) diff --git a/src/DependencyInjection/DoctrineExtension.php b/src/DependencyInjection/DoctrineExtension.php index 3a976bdc..8d3e4028 100644 --- a/src/DependencyInjection/DoctrineExtension.php +++ b/src/DependencyInjection/DoctrineExtension.php @@ -445,12 +445,12 @@ private function detectMappingType(string $directory, ContainerBuilder $containe */ public static function textContainsAnnotation(string $quotedMappingObjectName, string $content): bool { - return preg_match('/^(?:[ ]\*|\/\*\*)[ ]@ # Match phpdoc start or line with an at + return preg_match('/^(?:[ ]\*|\/\*\*)[ ]@ # Match phpdoc start or line with an at \\\\? # Can start with antislash - ([a-zA-Z_\x80-\xff][a-zA-Z0-9_\x80-\xff]*\\\\?)* # Match 0-n namespace, the antislash is optionnal as it may be a prefix if an alias is used + ([a-zA-Z_\x80-\xff][a-zA-Z0-9_\x80-\xff]*\\\\)* # Match namespace components ending with antislash ' . $quotedMappingObjectName . ' # The target class - [a-zA-Z0-9_\x80-\xff]* # Match a suffix if the class is aliased - \b/mx', $content) === 1; + \b # Match word boundary + /mx', $content) === 1; } /** diff --git a/tests/DependencyInjection/DoctrineExtensionTest.php b/tests/DependencyInjection/DoctrineExtensionTest.php index 8d3bbe31..1407e9f4 100644 --- a/tests/DependencyInjection/DoctrineExtensionTest.php +++ b/tests/DependencyInjection/DoctrineExtensionTest.php @@ -1554,13 +1554,15 @@ public function testDetectMappingType(string $bundle, string $expectedType, stri #[TestWith([' * @\\Doctrine\\ORM\\Mapping\\Entity', true], 'Complete namespace with starting slash')] #[TestWith([' * @Doctrine\\ORM\\Mapping\\Entity', true], 'Complete namespace without starting slash')] #[TestWith([' * @Entity', true], 'Use of the class')] + #[TestWith([' * @Entity()', true], 'With parentheses')] #[TestWith(['/** @Entity */', true], 'Comment start')] - #[TestWith([' * @ORMEntity', true], 'Use of the class with alias prefixing')] - #[TestWith([' * @EntityORM', true], 'Use of the class with alias suffixing')] - #[TestWith([' * @ormEntity', true], 'namespace can start with lowercase')] - #[TestWith([' * @_ORMEntity', true], 'namespace can start with underscore')] - #[TestWith([" * @\x80ORMEntity", true], 'namespace can start with char from x80-Xff')] - #[TestWith([" * @orm0_\x80Entity", true], 'namespace can contain number, underscore and char from x80-Xff')] + #[TestWith(["/**\n * @Entity\n */", true], 'Multiline phpdoc')] + #[TestWith([' * @orm\\Entity', true], 'namespace can start with lowercase')] + #[TestWith([' * @_ORM\\Entity', true], 'namespace can start with underscore')] + #[TestWith([" * @\x80ORM\\Entity", true], 'namespace can start with char from x80-Xff')] + #[TestWith([" * @orm0_\x80\\Entity", true], 'namespace can contain number, underscore and char from x80-Xff')] + #[TestWith([' * @ORMEntity', false], 'Use of the class with prefix')] + #[TestWith([' * @EntityORM', false], 'Use of the class with suffix')] #[TestWith([' * @package testEntity', false], 'Annotation with Entity as value')] #[TestWith([' * @entity', false], 'Lowercase use of the class')] #[TestWith([' * @1ORMEntity', false], 'namespace can\'t start with number')] From 6a620f966a16f70f6c91ff50dd86e423dd9b9197 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 3 Nov 2025 15:15:10 +0000 Subject: [PATCH 14/14] Bump doctrine/.github from 12.1.0 to 12.2.0 Bumps [doctrine/.github](https://github.com/doctrine/.github) from 12.1.0 to 12.2.0. - [Release notes](https://github.com/doctrine/.github/releases) - [Commits](https://github.com/doctrine/.github/compare/12.1.0...v12.2.0) --- updated-dependencies: - dependency-name: doctrine/.github dependency-version: 12.2.0 dependency-type: direct:production update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] --- .github/workflows/coding-standards.yml | 2 +- .github/workflows/composer-lint.yml | 2 +- .github/workflows/documentation.yml | 2 +- .github/workflows/release-on-milestone-closed.yml | 2 +- .github/workflows/static-analysis.yml | 2 +- .github/workflows/website-schema.yml | 2 +- 6 files changed, 6 insertions(+), 6 deletions(-) diff --git a/.github/workflows/coding-standards.yml b/.github/workflows/coding-standards.yml index 0f6dc856..8e159f1d 100644 --- a/.github/workflows/coding-standards.yml +++ b/.github/workflows/coding-standards.yml @@ -26,6 +26,6 @@ on: jobs: coding-standards: name: "Coding Standards" - uses: "doctrine/.github/.github/workflows/coding-standards.yml@12.1.0" + uses: "doctrine/.github/.github/workflows/coding-standards.yml@v12.2.0" with: composer-options: "--prefer-dist --prefer-stable" diff --git a/.github/workflows/composer-lint.yml b/.github/workflows/composer-lint.yml index 4b296926..a9876185 100644 --- a/.github/workflows/composer-lint.yml +++ b/.github/workflows/composer-lint.yml @@ -17,4 +17,4 @@ on: jobs: composer-lint: name: "Composer Lint" - uses: "doctrine/.github/.github/workflows/composer-lint.yml@12.1.0" + uses: "doctrine/.github/.github/workflows/composer-lint.yml@v12.2.0" diff --git a/.github/workflows/documentation.yml b/.github/workflows/documentation.yml index 93fd4c65..7722f764 100644 --- a/.github/workflows/documentation.yml +++ b/.github/workflows/documentation.yml @@ -17,4 +17,4 @@ on: jobs: documentation: name: "Documentation" - uses: "doctrine/.github/.github/workflows/documentation.yml@12.1.0" \ No newline at end of file + uses: "doctrine/.github/.github/workflows/documentation.yml@v12.2.0" \ No newline at end of file diff --git a/.github/workflows/release-on-milestone-closed.yml b/.github/workflows/release-on-milestone-closed.yml index 89dba39e..63421012 100644 --- a/.github/workflows/release-on-milestone-closed.yml +++ b/.github/workflows/release-on-milestone-closed.yml @@ -8,7 +8,7 @@ on: jobs: release: name: "Git tag, release & create merge-up PR" - uses: "doctrine/.github/.github/workflows/release-on-milestone-closed.yml@12.1.0" + uses: "doctrine/.github/.github/workflows/release-on-milestone-closed.yml@v12.2.0" secrets: GIT_AUTHOR_EMAIL: ${{ secrets.GIT_AUTHOR_EMAIL }} GIT_AUTHOR_NAME: ${{ secrets.GIT_AUTHOR_NAME }} diff --git a/.github/workflows/static-analysis.yml b/.github/workflows/static-analysis.yml index 2f0ce4cc..19cd9344 100644 --- a/.github/workflows/static-analysis.yml +++ b/.github/workflows/static-analysis.yml @@ -26,4 +26,4 @@ on: jobs: static-analysis: name: "Static Analysis" - uses: "doctrine/.github/.github/workflows/phpstan.yml@12.1.0" + uses: "doctrine/.github/.github/workflows/phpstan.yml@v12.2.0" diff --git a/.github/workflows/website-schema.yml b/.github/workflows/website-schema.yml index f56b7241..80312010 100644 --- a/.github/workflows/website-schema.yml +++ b/.github/workflows/website-schema.yml @@ -18,4 +18,4 @@ on: jobs: json-validate: name: "Validate JSON schema" - uses: "doctrine/.github/.github/workflows/website-schema.yml@12.1.0" + uses: "doctrine/.github/.github/workflows/website-schema.yml@v12.2.0"