diff --git a/.github/workflows/code_analysis.yaml b/.github/workflows/code_analysis.yaml index c0680bbfa..3ccf73469 100644 --- a/.github/workflows/code_analysis.yaml +++ b/.github/workflows/code_analysis.yaml @@ -17,6 +17,15 @@ jobs: # tip: add "--ansi" to commands in CI to make them full of colors run: vendor/bin/ecs check src --ansi + - + name: PHPStan + run: vendor/bin/phpstan analyse + + # check that the composer.json and composer.lock files are valid + - + name: Composer Validate + run: composer validate --strict + name: ${{ matrix.actions.name }} runs-on: ubuntu-latest diff --git a/.travis.yml b/.travis.yml index 641a0a424..61c937b8a 100644 --- a/.travis.yml +++ b/.travis.yml @@ -48,8 +48,6 @@ before_script: - export PATH=$PATH:$PWD/vendor/bin script: - # this checks that the source code follows the Bolt Code Syntax rules - - ./vendor/bin/phpstan analyse -c phpstan.neon src # run EsLint on Javascript files - npm run lint # run StyleLint on SCSS @@ -62,8 +60,6 @@ script: - ./bin/console lint:xliff translations # this checks that the application doesn't use dependencies with known security vulnerabilities - ./bin/console security:check - # this checks that the composer.json and composer.lock files are valid - - composer validate --strict # this checks that Doctrine's mapping configurations are valid - ./bin/console doctrine:schema:validate --skip-sync -vvv --no-interaction # run PHP Unit @@ -74,4 +70,3 @@ script: - travis_retry make db-reset-without-images && make behat-js-quiet # Upload Behat logs - ./vendor/bin/upload-textfiles "var/log/behat-reports/*.log" - diff --git a/phpstan.neon b/phpstan.neon index 7b6da6a74..975cd5ec4 100644 --- a/phpstan.neon +++ b/phpstan.neon @@ -1,6 +1,10 @@ parameters: tmpDir: var/cache/ecs level: 5 + + paths: + - src + symfony: container_xml_path: '%rootDir%/../../../var/cache/dev/Bolt_KernelDevDebugContainer.xml'