Skip to content

Commit bbbc4c0

Browse files
authored
Merge pull request #1364 from zavitkov/zavitkov/feature/fix-sf7-deprecations
SF7 deprecations fix
2 parents 8179bb9 + 60ff029 commit bbbc4c0

File tree

6 files changed

+10
-19
lines changed

6 files changed

+10
-19
lines changed

composer.json

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -51,7 +51,7 @@
5151
"require-dev": {
5252
"ext-pcntl": "*",
5353
"phpunit/phpunit": "^9.5",
54-
"phpstan/phpstan": "^0.12",
54+
"phpstan/phpstan": "^1.0",
5555
"queue-interop/queue-spec": "^0.6.2",
5656
"symfony/browser-kit": "^6.2|^7.0",
5757
"symfony/config": "^6.2|^7.0",
@@ -60,9 +60,9 @@
6060
"symfony/dependency-injection": "^6.2|^7.0",
6161
"symfony/event-dispatcher": "^6.2|^7.0",
6262
"symfony/expression-language": "^6.2|^7.0",
63-
"symfony/http-kernel": "^^6.2|^7.0",
63+
"symfony/http-kernel": "^6.2|^7.0",
6464
"symfony/filesystem": "^6.2|^7.0",
65-
"symfony/framework-bundle": "^^6.2|^7.0",
65+
"symfony/framework-bundle": "^6.2|^7.0",
6666
"symfony/validator": "^6.2|^7.0",
6767
"symfony/yaml": "^6.2|^7.0",
6868
"empi89/php-amqp-stubs": "*@dev",

phpstan.neon

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
parameters:
2-
excludes_analyse:
2+
excludePaths:
33
- docs
44
- bin
55
- docker

pkg/enqueue-bundle/DependencyInjection/EnqueueExtension.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -22,10 +22,10 @@
2222
use Symfony\Component\Config\FileLocator;
2323
use Symfony\Component\Config\Resource\FileResource;
2424
use Symfony\Component\DependencyInjection\ContainerBuilder;
25+
use Symfony\Component\DependencyInjection\Extension\Extension;
2526
use Symfony\Component\DependencyInjection\Extension\PrependExtensionInterface;
2627
use Symfony\Component\DependencyInjection\Loader\YamlFileLoader;
2728
use Symfony\Component\DependencyInjection\Reference;
28-
use Symfony\Component\HttpKernel\DependencyInjection\Extension;
2929

3030
final class EnqueueExtension extends Extension implements PrependExtensionInterface
3131
{

pkg/enqueue-bundle/Profiler/AbstractMessageQueueCollector.php

Lines changed: 1 addition & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -59,27 +59,19 @@ public function prettyPrintPriority($priority)
5959
}
6060

6161
/**
62-
* @param mixed $body
63-
*
6462
* @return string
6563
*/
6664
public function ensureString($body)
6765
{
6866
return is_string($body) ? $body : JSON::encode($body);
6967
}
7068

71-
/**
72-
* {@inheritdoc}
73-
*/
7469
public function getName(): string
7570
{
7671
return 'enqueue.message_queue';
7772
}
7873

79-
/**
80-
* {@inheritdoc}
81-
*/
82-
public function reset()
74+
public function reset(): void
8375
{
8476
$this->data = [];
8577
}

pkg/enqueue-bundle/Profiler/MessageQueueCollector.php

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -4,11 +4,10 @@
44

55
use Symfony\Component\HttpFoundation\Request;
66
use Symfony\Component\HttpFoundation\Response;
7-
use Throwable;
87

98
class MessageQueueCollector extends AbstractMessageQueueCollector
109
{
11-
public function collect(Request $request, Response $response, Throwable $exception = null)
10+
public function collect(Request $request, Response $response, ?\Throwable $exception = null): void
1211
{
1312
$this->collectInternal($request, $response);
1413
}

pkg/enqueue-bundle/Tests/Unit/DependencyInjection/EnqueueExtensionTest.php

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -13,21 +13,21 @@
1313
use Enqueue\Test\ClassExtensionTrait;
1414
use PHPUnit\Framework\TestCase;
1515
use Symfony\Component\DependencyInjection\ContainerBuilder;
16+
use Symfony\Component\DependencyInjection\Extension\Extension;
1617
use Symfony\Component\DependencyInjection\Reference;
17-
use Symfony\Component\HttpKernel\DependencyInjection\Extension;
1818

1919
class EnqueueExtensionTest extends TestCase
2020
{
2121
use ClassExtensionTrait;
2222

2323
public function testShouldImplementConfigurationInterface()
2424
{
25-
self::assertClassExtends(Extension::class, EnqueueExtension::class);
25+
$this->assertClassExtends(Extension::class, EnqueueExtension::class);
2626
}
2727

2828
public function testShouldBeFinal()
2929
{
30-
self::assertClassFinal(EnqueueExtension::class);
30+
$this->assertClassFinal(EnqueueExtension::class);
3131
}
3232

3333
public function testCouldBeConstructedWithoutAnyArguments()

0 commit comments

Comments
 (0)
pFad - Phonifier reborn

Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy