Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Update PHPStan packages to v2 (major) #540

Merged
merged 2 commits into from
Nov 19, 2024
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
8 changes: 4 additions & 4 deletions composer.json
Original file line number Diff line number Diff line change
Expand Up @@ -27,10 +27,10 @@
"lcobucci/coding-standard": "^11.1",
"mikey179/vfsstream": "^1.6.12",
"phpstan/extension-installer": "^1.4",
"phpstan/phpstan": "^1.12",
"phpstan/phpstan-deprecation-rules": "^1.2",
"phpstan/phpstan-phpunit": "^1.4",
"phpstan/phpstan-strict-rules": "^1.6",
"phpstan/phpstan": "^2.0",
"phpstan/phpstan-deprecation-rules": "^2.0",
"phpstan/phpstan-phpunit": "^2.0",
"phpstan/phpstan-strict-rules": "^2.0",
"phpunit/phpunit": "^11.4",
"squizlabs/php_codesniffer": "^3.10",
"symfony/yaml": "^7.1"
Expand Down
78 changes: 38 additions & 40 deletions composer.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

4 changes: 3 additions & 1 deletion src/Compiler.php
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,7 @@
use Symfony\Component\DependencyInjection\Dumper\PhpDumper;
use Symfony\Component\Filesystem\Filesystem;

use function array_is_list;
use function array_pop;
use function assert;
use function dirname;
Expand Down Expand Up @@ -86,8 +87,9 @@
$options['inline_class_loader'] = $options['inline_factories'];

$content = (new PhpDumper($container))->dump($options);
assert(is_array($content));
assert(is_array($content) && ! array_is_list($content));

Check warning on line 90 in src/Compiler.php

View workflow job for this annotation

GitHub Actions / Mutation tests (locked, 8.2, ubuntu-latest)

Escaped Mutant for Mutator "LogicalAnd": @@ @@ $options['inline_factories'] = $options['debug'] === false; $options['inline_class_loader'] = $options['inline_factories']; $content = (new PhpDumper($container))->dump($options); - assert(is_array($content) && !array_is_list($content)); + assert(is_array($content) || !array_is_list($content)); // @phpstan-ignore return.type return $content; }

Check warning on line 90 in src/Compiler.php

View workflow job for this annotation

GitHub Actions / Mutation tests (locked, 8.2, ubuntu-latest)

Escaped Mutant for Mutator "LogicalAnd": @@ @@ $options['inline_factories'] = $options['debug'] === false; $options['inline_class_loader'] = $options['inline_factories']; $content = (new PhpDumper($container))->dump($options); - assert(is_array($content) && !array_is_list($content)); + assert(is_array($content) || !array_is_list($content)); // @phpstan-ignore return.type return $content; }

// @phpstan-ignore return.type
return $content;
}

Expand Down
Loading