Skip to content

brettdh/phpstan-test

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

2 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

PHPStan include path testing

I'm trying to figure out how to set include_path when running PHPStan, so that PHPStan recognizes functions required from files in includes/.

Here's what I get in my minimal testing:

Using php.ini

➜ ./phpstan ini
Using php.ini to set include_path
Note: Using configuration file /app/phpstan.neon.
 1/1 [▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓] 100%

 ------ ---------------------------------------------------------------------
  Line   foo.php
 ------ ---------------------------------------------------------------------
  5      Function bar not found.
         💡 Learn more at https://phpstan.org/user-guide/discovering-symbols
 ------ ---------------------------------------------------------------------


 [ERROR] Found 1 error

Using --autoload-file (or bootstrapFiles in config)

➜ ./phpstan
Using bootstrap file to set include_path
Note: Using configuration file /app/phpstan.neon.
 1/1 [▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓] 100%

 ------ ---------------------------------------------------------------------
  Line   foo.php
 ------ ---------------------------------------------------------------------
  5      Function bar not found.
         💡 Learn more at https://phpstan.org/user-guide/discovering-symbols
 ------ ---------------------------------------------------------------------


 [ERROR] Found 1 error

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors