diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml index 113e6ef3ea2e4be27a9d342eee36ae2577b74f6f..9052568a336484d1a9f50165391ccc3c8b14e765 100644 --- a/.gitlab-ci.yml +++ b/.gitlab-ci.yml @@ -145,11 +145,14 @@ phpstan: - make composer-dev - mkdir .reports -p script: - - php composer/bin/phpstan analyse --memory-limit=1G --no-progress --level=$PHPSTAN_LEVEL > .reports/report-phpstan.xml + - php composer/bin/phpstan analyse --memory-limit=1G --no-progress --level=$PHPSTAN_LEVEL --error-format=gitlab > .reports/report-phpstan.json artifacts: + paths: + - .reports/report-phpstan.json + expire_in: 14 days when: always reports: - junit: .reports/report-phpstan.xml + codequality: .reports/report-phpstan.json test-unit: stage: tests diff --git a/phpstan.neon.dist b/phpstan.neon.dist index 588535a28f938fcffecae22109c8f3f46a88cb74..bc2526cc6f5c6c4ef92e29af121e7e2b5fdaca74 100644 --- a/phpstan.neon.dist +++ b/phpstan.neon.dist @@ -2,7 +2,7 @@ parameters: level: 0 phpVersion: 70200 # PHP 7.2 paths: - # - app/routes + - app/routes - lib # - tests scanFiles: @@ -20,7 +20,5 @@ parameters: RESTAPI\RouteMap: - error - halt - errorFormat: - junit ignoreErrors: # - '#Undefined variable#'