From 4ba6fe5a6ffdf53c1d3d34bfc2919a00284b922c Mon Sep 17 00:00:00 2001 From: Mathieu Santostefano Date: Tue, 24 Sep 2024 11:39:41 +0200 Subject: [PATCH] fix(phpstan): Fix deprecated config and lower the level from max to 8 --- README.md | 2 +- dist/sylius/phpstan.neon | 10 +++++----- resources/makefiles/testing.mk | 2 +- 3 files changed, 7 insertions(+), 7 deletions(-) diff --git a/README.md b/README.md index 3daf3c8..c1070fe 100644 --- a/README.md +++ b/README.md @@ -10,7 +10,7 @@ You will need : Then you can : -- Use this template project as a new project in Github. +- Use this template project as a new project in GitHub. - Clone your project and run `castor local:setup` inside it. - Clean the castor files if you don't want them in your project with `castor local:clean-up`. - Remove the `composer.lock` line in `apps/sylius/.gitignore` if you want to commit it. diff --git a/dist/sylius/phpstan.neon b/dist/sylius/phpstan.neon index 9558b4d..d032b4c 100644 --- a/dist/sylius/phpstan.neon +++ b/dist/sylius/phpstan.neon @@ -1,10 +1,10 @@ parameters: - level: max + level: 8 paths: - - %rootDir%/src/ - - checkMissingIterableValueType: false - checkGenericClassInNonGenericObjectType: false + - src/ + - plugins/ ignoreErrors: - '/Generator expects value type Symfony\\Component\\HttpKernel\\Bundle\\BundleInterface\, object given\./' +# - identifier: missingType.iterableValue +# - identifier: missingType.generics diff --git a/resources/makefiles/testing.mk b/resources/makefiles/testing.mk index 6ad7ec8..7829631 100644 --- a/resources/makefiles/testing.mk +++ b/resources/makefiles/testing.mk @@ -8,7 +8,7 @@ test.composer: ## Validate composer.json $(call symfony.composer,validate --strict) test.phpstan: ## Run PHPStan - ${PHPSTAN} analyse -c phpstan.neon src/ plugins/ + ${PHPSTAN} analyse -c phpstan.neon test.phpunit: ## Run PHPUnit ${PHPUNIT}