Skip to content

Commit

Permalink
Add support for Symfony 7
Browse files Browse the repository at this point in the history
  • Loading branch information
mbabker committed Oct 6, 2023
1 parent d6d0d31 commit 6f4ff81
Show file tree
Hide file tree
Showing 5 changed files with 17 additions and 20 deletions.
2 changes: 1 addition & 1 deletion Cache/CacheWarmer.php
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@ public function __construct(array $includePaths, MetadataFactoryInterface $metad
*
* @return string[] A list of classes or files to preload on PHP 7.4+
*/
public function warmUp($cacheDir)
public function warmUp(string $cacheDir): array
{
$finder = Finder::create()
->ignoreVCS(true)
Expand Down
5 changes: 1 addition & 4 deletions DependencyInjection/Configuration.php
Original file line number Diff line number Diff line change
Expand Up @@ -25,10 +25,7 @@ public function __construct($debug = false)
$this->debug = $debug;
}

/**
* @return TreeBuilder
*/
public function getConfigTreeBuilder()
public function getConfigTreeBuilder(): TreeBuilder
{
$tb = new TreeBuilder('jms_serializer');

Expand Down
2 changes: 1 addition & 1 deletion ExpressionLanguage/BasicSerializerFunctionsProvider.php
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ class BasicSerializerFunctionsProvider implements ExpressionFunctionProviderInte
/**
* @return ExpressionFunction[]
*/
public function getFunctions()
public function getFunctions(): array
{
return [
new ExpressionFunction('service', static function ($arg) {
Expand Down
2 changes: 1 addition & 1 deletion Tests/DependencyInjection/JMSSerializerExtensionTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@
use Symfony\Component\Config\Definition\Exception\InvalidConfigurationException;
use Symfony\Component\DependencyInjection\ContainerBuilder;
use Symfony\Component\DependencyInjection\Definition;
use Twig\Loader\ContainerRuntimeLoader;
use Twig\RuntimeLoader\ContainerRuntimeLoader;

class JMSSerializerExtensionTest extends TestCase
{
Expand Down
26 changes: 13 additions & 13 deletions composer.json
Original file line number Diff line number Diff line change
Expand Up @@ -24,26 +24,26 @@
"php": "^7.2 || ^8.0",
"jms/serializer": "^3.28",
"jms/metadata": "^2.6",
"symfony/dependency-injection": "^3.4 || ^4.0 || ^5.0 || ^6.0",
"symfony/framework-bundle": "^3.4 || ^4.0 || ^5.0 || ^6.0"
"symfony/dependency-injection": "^3.4 || ^4.0 || ^5.0 || ^6.0 || ^7.0",
"symfony/framework-bundle": "^3.4 || ^4.0 || ^5.0 || ^6.0 || ^7.0"
},
"require-dev": {
"doctrine/coding-standard": "^8.1",
"doctrine/orm": "^2.4",
"phpunit/phpunit": "^8.0 || ^9.0",
"symfony/expression-language": "^3.4 || ^4.0 || ^5.0 || ^6.0",
"symfony/finder": "^3.4 || ^4.0 || ^5.0 || ^6.0",
"symfony/form": "^3.4 || ^4.0 || ^5.0 || ^6.0",
"symfony/stopwatch": "^3.4 || ^4.0 || ^5.0 || ^6.0",
"symfony/templating": "^3.4 || ^4.0 || ^5.0 || ^6.0",
"symfony/twig-bundle": "^3.4 || ^4.0 || ^5.0 || ^6.0",
"symfony/uid": "^5.1 || ^6.0",
"symfony/validator": "^3.4 || ^4.0 || ^5.0 || ^6.0",
"symfony/yaml": "^3.4 || ^4.0 || ^5.0 || ^6.0"
"symfony/expression-language": "^3.4 || ^4.0 || ^5.0 || ^6.0 || ^7.0",
"symfony/finder": "^3.4 || ^4.0 || ^5.0 || ^6.0 || ^7.0",
"symfony/form": "^3.4 || ^4.0 || ^5.0 || ^6.0 || ^7.0",
"symfony/stopwatch": "^3.4 || ^4.0 || ^5.0 || ^6.0 || ^7.0",
"symfony/templating": "^3.4 || ^4.0 || ^5.0 || ^6.0 || ^7.0",
"symfony/twig-bundle": "^3.4 || ^4.0 || ^5.0 || ^6.0 || ^7.0",
"symfony/uid": "^5.1 || ^6.0 || ^7.0",
"symfony/validator": "^3.4 || ^4.0 || ^5.0 || ^6.0 || ^7.0",
"symfony/yaml": "^3.4 || ^4.0 || ^5.0 || ^6.0 || ^7.0"
},
"suggest": {
"symfony/expression-language": "Required for opcache preloading ^3.4 || ^4.0 || ^5.0 || ^6.0",
"symfony/finder": "Required for cache warmup, supported versions ^3.4 || ^4.0 || ^5.0 || ^6.0"
"symfony/expression-language": "Required for opcache preloading ^3.4 || ^4.0 || ^5.0 || ^6.0 || ^7.0",
"symfony/finder": "Required for cache warmup, supported versions ^3.4 || ^4.0 || ^5.0 || ^6.0 || ^7.0"
},
"config": {
"allow-plugins": {
Expand Down

0 comments on commit 6f4ff81

Please sign in to comment.