Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion .github/workflows/build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@ jobs:
- 8.5
symfony-version:
- 6.4.*
- 7.*
- 7.4.*
dependencies: [lowest, highest]
name: 'PHP ${{ matrix.php-version }} + Symfony ${{ matrix.symfony-version }} + ${{ matrix.dependencies }} dependencies'

Expand Down
31 changes: 31 additions & 0 deletions phpstan-baseline.neon
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,31 @@ parameters:
ignoreErrors:
-
identifier: trait.unused

-
message: '#^Call to method scalarNode\(\) on an unknown class Symfony\\Component\\Config\\Definition\\Builder\\NodeBuilder\<Symfony\\Component\\Config\\Definition\\Builder\\ArrayNodeDefinition\>\.$#'
identifier: class.notFound
count: 1
path: src/DependencyInjection/Configuration.php

-
message: '#^Cannot call method defaultValue\(\) on mixed\.$#'
identifier: method.nonObject
count: 1
path: src/DependencyInjection/Configuration.php

-
message: '#^Cannot call method end\(\) on mixed\.$#'
identifier: method.nonObject
count: 2
path: src/DependencyInjection/Configuration.php

-
message: '#^Method Speicher210\\FunctionalTestBundle\\DependencyInjection\\Configuration\:\:getConfigTreeBuilder\(\) return type with generic class Symfony\\Component\\Config\\Definition\\Builder\\TreeBuilder does not specify its types\: T$#'
identifier: missingType.generics
count: 1
path: src/DependencyInjection/Configuration.php

-
message: '#^Parameter \#1 \$string of function Psl\\Str\\trim expects string, mixed given\.$#'
identifier: argument.type
Expand Down Expand Up @@ -67,3 +92,9 @@ parameters:
identifier: argument.type
count: 1
path: src/Test/bootstrap.php

-
message: '#^Call to function method_exists\(\) with Doctrine\\ORM\\Configuration and ''enableNativeLazyObj…'' will always evaluate to true\.$#'
identifier: function.alreadyNarrowedType
count: 1
path: src/Test/Doctrine/ORM/Query/AST/FunctionTestCase.php
8 changes: 8 additions & 0 deletions src/Test/Doctrine/ORM/Query/AST/FunctionTestCase.php
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,10 @@
use Doctrine\ORM\Query\AST\Functions\FunctionNode;
use PHPUnit\Framework\TestCase;

use function method_exists;

use const PHP_VERSION_ID;

abstract class FunctionTestCase extends TestCase
{
/**
Expand All @@ -24,6 +28,10 @@ protected function getEntityManager(): EntityManager
$configuration->setProxyDir(__DIR__ . '/Fixtures/Proxies');
$configuration->setProxyNamespace(__NAMESPACE__ . '\Proxy');
$configuration->setAutoGenerateProxyClasses(true);
if (PHP_VERSION_ID >= 80400 && method_exists($configuration, 'enableNativeLazyObjects')) {
$configuration->enableNativeLazyObjects(true);
}

$configuration->setMetadataDriverImpl(new AttributeDriver([__DIR__ . '/Fixtures']));
foreach ($this->registeredStringFunctions() as $name => $class) {
$configuration->addCustomStringFunction($name, $class);
Expand Down