summaryrefslogtreecommitdiff
path: root/test/linter/test_phpstan.vader
diff options
context:
space:
mode:
authorFilippo Tessarotto <zoeslam@gmail.com>2021-07-04 14:16:55 +0200
committerGitHub <noreply@github.com>2021-07-04 21:16:55 +0900
commit12d8803015d5850d0e4f8fd0a713262b86a195d7 (patch)
treeb513783981d110a9bab228bddd6b5f96f8fa0952 /test/linter/test_phpstan.vader
parent52563f91816f86fbc3e6d9f01ca50a8d85fdbee5 (diff)
downloadale-12d8803015d5850d0e4f8fd0a713262b86a195d7.zip
[PHP] PhpStan also looks for .dist config file (#3765)
* [PHP] PhpStan also looks for .dist config file * Add tests
Diffstat (limited to 'test/linter/test_phpstan.vader')
-rw-r--r--test/linter/test_phpstan.vader10
1 files changed, 10 insertions, 0 deletions
diff --git a/test/linter/test_phpstan.vader b/test/linter/test_phpstan.vader
index 813fe448..9f73c18a 100644
--- a/test/linter/test_phpstan.vader
+++ b/test/linter/test_phpstan.vader
@@ -58,6 +58,16 @@ Execute(Configuration file exists in current directory):
\ ale#Escape('phpstan') . ' analyze --no-progress --errorFormat raw %s'
\ ]
+Execute(Configuration dist file exists in current directory):
+ call writefile(['parameters:', ' level: 7'], './phpstan.neon.dist')
+ let g:ale_php_phpstan_level = ''
+ let g:ale_php_phpstan_configuration = ''
+
+ AssertLinter 'phpstan', [
+ \ ale#Escape('phpstan') . ' --version',
+ \ ale#Escape('phpstan') . ' analyze --no-progress --errorFormat raw %s'
+ \ ]
+
Execute(Configuration file exists in current directory, but force phpstan level):
call writefile(['parameters:', ' level: 7'], './phpstan.neon')
let g:ale_php_phpstan_configuration = ''