diff --git a/Tests/Payload/GeneratorTest.php b/Tests/Payload/GeneratorTest.php index 6010395..2e35063 100755 --- a/Tests/Payload/GeneratorTest.php +++ b/Tests/Payload/GeneratorTest.php @@ -82,7 +82,7 @@ public function testGetServerInfo(): void */ public function testGetRequestInfo(): void { - $container = self::getContainer(); + $container = static::$kernel->getContainer(); $generator = $this->getGenerator(); $request = $container->get('request_stack')->getCurrentRequest(); @@ -185,15 +185,11 @@ public function testGetExceptionPayload(): void $this->assertEquals($serverInfo, $payload['server']); } - protected static function getContainer(): ContainerInterface - { - return static::$container ?? static::$kernel->getContainer(); - } - private function getGenerator(): Generator { + $container = static::$kernel->getContainer(); /** @var $generator Generator */ - $generator = self::getContainer()->get('test.' . Generator::class); + $generator = $container->get('test.' . Generator::class); return $generator; } } diff --git a/composer.json b/composer.json index 0db837d..bfe5114 100755 --- a/composer.json +++ b/composer.json @@ -28,17 +28,17 @@ "require": { "php": ">=8.0.2", "rollbar/rollbar": "^3.1|^4.0", - "symfony/dependency-injection": "^5.4|^6.2", - "symfony/config": "^5.4|^6.2", - "symfony/http-kernel": "^5.4|^6.2", + "symfony/dependency-injection": "^5.4|^6.2|^7.0", + "symfony/config": "^5.4|^6.2|^7.0", + "symfony/http-kernel": "^5.4|^6.2|^7.0", "symfony/monolog-bundle": "^3.8", - "symfony/serializer": "^5.4|^6.2", - "ext-json": "*", + "symfony/serializer": "^5.4|^6.2|^7.0", "symfony/security-core": "^7.0" + "ext-json": "*", }, "require-dev": { "phpunit/phpunit": "^9.6|^10.1", - "symfony/framework-bundle": "^5.4|^6.2", + "symfony/framework-bundle": "^5.4|^6.2|^7.0", "squizlabs/php_codesniffer": "^3.7", "matthiasnoback/symfony-dependency-injection-test": "^4.3" },