From ce94e19339df3f416dd38eb20a34c58e927bcfe3 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Maur=C3=ADcio=20Meneghini=20Fauth?= Date: Sat, 18 Aug 2018 13:56:33 -0300 Subject: [PATCH] Upgrade phpstan to version 0.10 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit - Add level and paths to configuration file Signed-off-by: MaurĂ­cio Meneghini Fauth --- composer.json | 2 +- phpstan.neon | 5 +++-- test/ci-phpstan | 3 +-- 3 files changed, 5 insertions(+), 5 deletions(-) diff --git a/composer.json b/composer.json index ef9b5f402a..ef057c6f7b 100644 --- a/composer.json +++ b/composer.json @@ -89,7 +89,7 @@ "bacon/bacon-qr-code": "^1.0", "samyoul/u2f-php-server": "^1.1", "phpmyadmin/coding-standard": "^0.3", - "phpstan/phpstan": "^0.9.2" + "phpstan/phpstan": "^0.10.3" }, "extra": { "branch-alias": { diff --git a/phpstan.neon b/phpstan.neon index 6c305e8062..f5576b1bec 100644 --- a/phpstan.neon +++ b/phpstan.neon @@ -1,4 +1,7 @@ parameters: + level: 0 + paths: + - %rootDir%/../../../ bootstrap: %rootDir%/../../../test/bootstrap-phpstan.php reportUnmatchedIgnoredErrors: false ignoreErrors: @@ -27,8 +30,6 @@ parameters: - '#Undefined variable: \$(unsaved_values|is_upload)#'#tbl_change.php - '#Undefined variable: \$max_upload_size#'#tbl_import.php - '#Undefined variable: \$(repobase|fullrevision|revision|repobranchbase|branch)#'#Footer.php - - excludes_analyse: - %rootDir%/../../../test/EnvironmentTest.php - %rootDir%/../../../test/libraries/FilesTest.php diff --git a/test/ci-phpstan b/test/ci-phpstan index 0d1c984109..5f8db42f43 100755 --- a/test/ci-phpstan +++ b/test/ci-phpstan @@ -3,5 +3,4 @@ cd $(dirname $0)/../ echo "Running in : $(pwd)" -# 1G is a litte high, should use < 512M (less ram + a lot of code = bigger risk of crash) -./vendor/bin/phpstan analyse ./ --configuration=phpstan.neon --level=0 --memory-limit=1G +./vendor/bin/phpstan analyse