Переглянути джерело

Merge pull request #8476 from localheinz/feature/config

Enhancement: Configure paths and autoload files via phpstan/config.neon
Jordi Boggiano 5 роки тому
батько
коміт
23b3118065
2 змінених файлів з 6 додано та 1 видалено
  1. 1 1
      .travis.yml
  2. 5 0
      phpstan/config.neon

+ 1 - 1
.travis.yml

@@ -65,7 +65,7 @@ script:
   # Run PHPStan
   - if [[ $PHPSTAN == "1" ]]; then
       bin/composer require --dev phpstan/phpstan-shim:^0.11 --ignore-platform-reqs &&
-      vendor/bin/phpstan.phar analyse src tests --configuration=phpstan/config.neon --autoload-file=phpstan/autoload.php;
+      vendor/bin/phpstan.phar analyse --configuration=phpstan/config.neon;
     fi
 
 before_deploy:

+ 5 - 0
phpstan/config.neon

@@ -1,4 +1,6 @@
 parameters:
+    autoload_files:
+        - phpstan/autoload.php
     level: 0
     excludes_analyse:
         - 'tests/Composer/Test/Fixtures'
@@ -39,3 +41,6 @@ parameters:
         # parent call in test mocks
         - '~^Composer\\Test\\Mock\\HttpDownloaderMock::__construct\(\) does not call parent constructor from Composer\\Util\\HttpDownloader\.$~'
         - '~^Composer\\Test\\Mock\\InstallationManagerMock::__construct\(\) does not call parent constructor from Composer\\Installer\\InstallationManager\.$~'
+    paths:
+        - src
+        - tests