Skip to content

Commit

Permalink
try using Kernel version
Browse files Browse the repository at this point in the history
  • Loading branch information
dmaicher committed Dec 7, 2023
1 parent 28f6488 commit 208a782
Showing 1 changed file with 2 additions and 3 deletions.
5 changes: 2 additions & 3 deletions Tests/DependencyInjection/Fixtures/DbalTestKernel.php
Original file line number Diff line number Diff line change
Expand Up @@ -10,12 +10,11 @@
use Symfony\Component\DependencyInjection\ContainerBuilder;
use Symfony\Component\HttpKernel\Bundle\Bundle;
use Symfony\Component\HttpKernel\Kernel;
use Symfony\Component\Validator\Mapping\Loader\AnnotationLoader;

use function class_exists;
use function md5;
use function mt_rand;
use function sys_get_temp_dir;
use function version_compare;

class DbalTestKernel extends Kernel
{
Expand Down Expand Up @@ -48,7 +47,7 @@ public function registerContainerConfiguration(LoaderInterface $loader): void
'secret' => 'F00',
'http_method_override' => false,
'annotations' => [
'enabled' => class_exists(AnnotationLoader::class),
'enabled' => version_compare(Kernel::VERSION, '7.0.0', '<'),
],
]);

Expand Down

0 comments on commit 208a782

Please sign in to comment.