Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Commit b23a087

Browse files
committed
Merge branch '6.2' into 6.3
* 6.2: Fix CS Compatibility with doctrine/annotations 2 [Console] Fix a test when pcntl is not available (following #48329) [FrameworkBundle] fix: fix typo about help
2 parents 926b450 + 813491f commit b23a087

File tree

18 files changed

+31
-18
lines changed

18 files changed

+31
-18
lines changed

composer.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -124,7 +124,7 @@
124124
"async-aws/sqs": "^1.0",
125125
"async-aws/sns": "^1.0",
126126
"cache/integration-tests": "dev-master",
127-
"doctrine/annotations": "^1.13.1",
127+
"doctrine/annotations": "^1.13.1|^2",
128128
"doctrine/collections": "^1.0|^2.0",
129129
"doctrine/data-fixtures": "^1.1",
130130
"doctrine/dbal": "^2.13.1|^3.0",

src/Symfony/Bridge/Doctrine/Tests/PropertyInfo/DoctrineExtractorTest.php

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,6 +15,7 @@
1515
use Doctrine\DBAL\Types\Type as DBALType;
1616
use Doctrine\ORM\EntityManager;
1717
use Doctrine\ORM\Mapping\Column;
18+
use Doctrine\ORM\ORMSetup;
1819
use Doctrine\ORM\Tools\Setup;
1920
use PHPUnit\Framework\TestCase;
2021
use Symfony\Bridge\Doctrine\PropertyInfo\DoctrineExtractor;
@@ -33,7 +34,9 @@ class DoctrineExtractorTest extends TestCase
3334
{
3435
private function createExtractor()
3536
{
36-
$config = Setup::createAnnotationMetadataConfiguration([__DIR__.\DIRECTORY_SEPARATOR.'Fixtures'], true);
37+
$config = class_exists(ORMSetup::class)
38+
? ORMSetup::createAnnotationMetadataConfiguration([__DIR__.\DIRECTORY_SEPARATOR.'Fixtures'], true)
39+
: Setup::createAnnotationMetadataConfiguration([__DIR__.\DIRECTORY_SEPARATOR.'Fixtures'], true);
3740
$entityManager = EntityManager::create(['driver' => 'pdo_sqlite'], $config);
3841

3942
if (!DBALType::hasType('foo')) {

src/Symfony/Bridge/Doctrine/composer.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -42,7 +42,7 @@
4242
"symfony/validator": "^5.4|^6.0",
4343
"symfony/translation": "^5.4|^6.0",
4444
"symfony/var-dumper": "^5.4|^6.0",
45-
"doctrine/annotations": "^1.10.4",
45+
"doctrine/annotations": "^1.10.4|^2",
4646
"doctrine/collections": "^1.0|^2.0",
4747
"doctrine/data-fixtures": "^1.1",
4848
"doctrine/dbal": "^2.13.1|^3.0",

src/Symfony/Bridge/PhpUnit/Legacy/SymfonyTestsListenerTrait.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -133,7 +133,7 @@ public function startTestSuite($suite)
133133
if (!class_exists(AnnotationRegistry::class, false) && class_exists(AnnotationRegistry::class)) {
134134
if (method_exists(AnnotationRegistry::class, 'registerUniqueLoader')) {
135135
AnnotationRegistry::registerUniqueLoader('class_exists');
136-
} else {
136+
} elseif (method_exists(AnnotationRegistry::class, 'registerLoader')) {
137137
AnnotationRegistry::registerLoader('class_exists');
138138
}
139139
}

src/Symfony/Bridge/PhpUnit/bootstrap.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -30,7 +30,7 @@
3030
if (!class_exists(AnnotationRegistry::class, false) && class_exists(AnnotationRegistry::class)) {
3131
if (method_exists(AnnotationRegistry::class, 'registerUniqueLoader')) {
3232
AnnotationRegistry::registerUniqueLoader('class_exists');
33-
} else {
33+
} elseif (method_exists(AnnotationRegistry::class, 'registerLoader')) {
3434
AnnotationRegistry::registerLoader('class_exists');
3535
}
3636
}

src/Symfony/Bridge/Twig/composer.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,7 @@
2121
"twig/twig": "^2.13|^3.0.4"
2222
},
2323
"require-dev": {
24-
"doctrine/annotations": "^1.12",
24+
"doctrine/annotations": "^1.12|^2",
2525
"egulias/email-validator": "^2.1.10|^3",
2626
"league/html-to-markdown": "^5.0",
2727
"phpdocumentor/reflection-docblock": "^3.0|^4.0|^5.0",

src/Symfony/Bundle/FrameworkBundle/Command/ConfigDumpReferenceCommand.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -92,7 +92,7 @@ protected function execute(InputInterface $input, OutputInterface $output): int
9292

9393
$errorIo->comment([
9494
'Provide the name of a bundle as the first argument of this command to dump its default configuration. (e.g. <comment>config:dump-reference FrameworkBundle</comment>)',
95-
'For dumping a specific option, add its path as the second argument of this command. (e.g. <comment>config:dump-reference FrameworkBundle profiler.matcher</comment> to dump the <comment>framework.profiler.matcher</comment> configuration)',
95+
'For dumping a specific option, add its path as the second argument of this command. (e.g. <comment>config:dump-reference FrameworkBundle http_client.default_options</comment> to dump the <comment>framework.http_client.default_options</comment> configuration)',
9696
]);
9797

9898
return 0;

src/Symfony/Bundle/FrameworkBundle/DependencyInjection/FrameworkExtension.php

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1644,8 +1644,12 @@ private function registerAnnotationsConfiguration(array $config, ContainerBuilde
16441644
$loader->load('annotations.php');
16451645

16461646
if (!method_exists(AnnotationRegistry::class, 'registerUniqueLoader')) {
1647-
$container->getDefinition('annotations.dummy_registry')
1648-
->setMethodCalls([['registerLoader', ['class_exists']]]);
1647+
if (method_exists(AnnotationRegistry::class, 'registerLoader')) {
1648+
$container->getDefinition('annotations.dummy_registry')
1649+
->setMethodCalls([['registerLoader', ['class_exists']]]);
1650+
} else {
1651+
$container->removeDefinition('annotations.dummy_registry');
1652+
}
16491653
}
16501654

16511655
if ('none' === $config['cache']) {

src/Symfony/Bundle/FrameworkBundle/Resources/config/annotations.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -25,7 +25,7 @@
2525
->set('annotations.reader', AnnotationReader::class)
2626
->call('addGlobalIgnoredName', [
2727
'required',
28-
service('annotations.dummy_registry'), // dummy arg to register class_exists as annotation loader only when required
28+
service('annotations.dummy_registry')->ignoreOnInvalid(), // dummy arg to register class_exists as annotation loader only when required
2929
])
3030

3131
->set('annotations.dummy_registry', AnnotationRegistry::class)

src/Symfony/Bundle/FrameworkBundle/composer.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -33,7 +33,7 @@
3333
"symfony/routing": "^5.4|^6.0"
3434
},
3535
"require-dev": {
36-
"doctrine/annotations": "^1.13.1",
36+
"doctrine/annotations": "^1.13.1|^2",
3737
"doctrine/persistence": "^1.3|^2|^3",
3838
"symfony/asset": "^5.4|^6.0",
3939
"symfony/browser-kit": "^5.4|^6.0",

src/Symfony/Bundle/SecurityBundle/composer.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -30,7 +30,7 @@
3030
"symfony/security-http": "^6.2"
3131
},
3232
"require-dev": {
33-
"doctrine/annotations": "^1.10.4",
33+
"doctrine/annotations": "^1.10.4|^2",
3434
"symfony/asset": "^5.4|^6.0",
3535
"symfony/browser-kit": "^5.4|^6.0",
3636
"symfony/console": "^5.4|^6.0",

src/Symfony/Bundle/TwigBundle/composer.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -36,7 +36,7 @@
3636
"symfony/yaml": "^5.4|^6.0",
3737
"symfony/framework-bundle": "^5.4|^6.0",
3838
"symfony/web-link": "^5.4|^6.0",
39-
"doctrine/annotations": "^1.10.4"
39+
"doctrine/annotations": "^1.10.4|^2"
4040
},
4141
"conflict": {
4242
"symfony/framework-bundle": "<5.4",

src/Symfony/Component/Console/Tests/ApplicationTest.php

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2005,6 +2005,10 @@ public function testSetSignalsToDispatchEvent()
20052005

20062006
public function testSignalableCommandInterfaceWithoutSignals()
20072007
{
2008+
if (!\defined('SIGUSR1')) {
2009+
$this->markTestSkipped('SIGUSR1 not available');
2010+
}
2011+
20082012
$command = new SignableCommand(false);
20092013

20102014
$dispatcher = new EventDispatcher();

src/Symfony/Component/PropertyInfo/composer.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -32,7 +32,7 @@
3232
"symfony/dependency-injection": "^5.4|^6.0",
3333
"phpdocumentor/reflection-docblock": "^5.2",
3434
"phpstan/phpdoc-parser": "^1.0",
35-
"doctrine/annotations": "^1.10.4"
35+
"doctrine/annotations": "^1.10.4|^2"
3636
},
3737
"conflict": {
3838
"phpdocumentor/reflection-docblock": "<5.2",

src/Symfony/Component/Routing/Tests/Loader/AnnotationClassLoaderWithAnnotationsTest.php

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -26,7 +26,9 @@ protected function configureRoute(Route $route, \ReflectionClass $class, \Reflec
2626
{
2727
}
2828
};
29-
AnnotationRegistry::registerLoader('class_exists');
29+
if (method_exists(AnnotationRegistry::class, 'registerLoader')) {
30+
AnnotationRegistry::registerLoader('class_exists');
31+
}
3032
}
3133

3234
public function testDefaultRouteName()

src/Symfony/Component/Routing/composer.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,7 @@
2424
"symfony/yaml": "^5.4|^6.0",
2525
"symfony/expression-language": "^5.4|^6.0",
2626
"symfony/dependency-injection": "^5.4|^6.0",
27-
"doctrine/annotations": "^1.12",
27+
"doctrine/annotations": "^1.12|^2",
2828
"psr/log": "^1|^2|^3"
2929
},
3030
"conflict": {

src/Symfony/Component/Serializer/composer.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,7 @@
2020
"symfony/polyfill-ctype": "~1.8"
2121
},
2222
"require-dev": {
23-
"doctrine/annotations": "^1.12",
23+
"doctrine/annotations": "^1.12|^2",
2424
"phpdocumentor/reflection-docblock": "^3.2|^4.0|^5.0",
2525
"symfony/cache": "^5.4|^6.0",
2626
"symfony/config": "^5.4|^6.0",

src/Symfony/Component/Validator/composer.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -39,7 +39,7 @@
3939
"symfony/property-access": "^5.4|^6.0",
4040
"symfony/property-info": "^5.4|^6.0",
4141
"symfony/translation": "^5.4|^6.0",
42-
"doctrine/annotations": "^1.13",
42+
"doctrine/annotations": "^1.13|^2",
4343
"egulias/email-validator": "^2.1.10|^3"
4444
},
4545
"conflict": {

0 commit comments

Comments
 (0)