Commit graph

14 commits

Author SHA1 Message Date
Alexandre Gomes Gaigalas 727e7ccbfa Increase phpstan level from 7 to 8
- Fixed all phpstan errors and ignoreds.
 - False positives now have a "Why:" comment on phpstan config.
2023-02-19 00:19:10 -03:00
Henrique Moody be7e6672a1
Remove ignored error from PHPStan
Signed-off-by: Henrique Moody <henriquemoody@gmail.com>
2021-03-19 15:12:43 +01:00
Henrique Moody 44a60f67d9
Fix PHPStan issues
This commit will fix an issue but ignore two of them because it will
require some refactoring that won't be possible in a PATCH version.

Signed-off-by: Henrique Moody <henriquemoody@gmail.com>
2021-02-06 12:51:56 +01:00
Henrique Moody d532e942a5
Create mixin with rules names as methods
One of the reasons for this change is to spare some space on the
Validator class, leaving only real code there. However, the biggest
reason is that IDEs can auto-complete rules after Validator creates the
first rule.

Signed-off-by: Henrique Moody <henriquemoody@gmail.com>
2020-10-04 13:04:20 +02:00
Henrique Moody 642602fd43
Update version of PHPStan packages
Some amazing features had to be ignored because it conflicts with out
coring standards. I hope to soon fix them so we can use PHPStan to its
fullest potential.

Signed-off-by: Henrique Moody <henriquemoody@gmail.com>
2020-07-25 22:50:59 +02:00
Henrique Moody 95b499b627
Apply "phpstan/phpstan-deprecation-rules" rules
Signed-off-by: Henrique Moody <henriquemoody@gmail.com>
2019-05-05 15:18:09 +02:00
Henrique Moody d00ed89f3c
Apply "phpstan/phpstan-phpunit" rules
Signed-off-by: Henrique Moody <henriquemoody@gmail.com>
2019-05-05 15:04:56 +02:00
Henrique Moody 985b6fac25
Increate PHPStan level to 7
Signed-off-by: Henrique Moody <henriquemoody@gmail.com>
2019-02-04 01:12:08 +01:00
Henrique Moody 4519739f8b
Increate PHPStan level to 6
Signed-off-by: Henrique Moody <henriquemoody@gmail.com>
2019-02-04 01:09:49 +01:00
Henrique Moody 103a47e134
Increate PHPStan level to 5
Signed-off-by: Henrique Moody <henriquemoody@gmail.com>
2019-02-04 00:49:35 +01:00
Henrique Moody b007284857
Increate PHPStan level to 3
Signed-off-by: Henrique Moody <henriquemoody@gmail.com>
2019-02-04 00:44:08 +01:00
Henrique Moody f52097075b
Increase PHPStan level to 2
Signed-off-by: Henrique Moody <henriquemoody@gmail.com>
2019-02-04 00:29:13 +01:00
Gus Antoniassi b392fbb92e
Apply contribution guidelines to "SymbolicLink" rule
Co-authored-by: Henrique Moody <henriquemoody@gmail.com>
2018-12-06 20:56:51 +01:00
Henrique Moody 258a456eec
Setup PHPStan (PHP Static Analysis Tool)
Require "phpstan/phpstan" for development and add to the Travis CI
configuration file to execute the analysis when Travis executes the
build with the version 7.2 of PHP.

The level of the configuration is very week for now (just "1") and still
quite some changes had to be made in order to make the analysis pass. I
hope it does not take much time to increase the level of the strictness
of the analyses.

I tried to configure that before but because of dependencies with
"symfony/validator" it was not possible.

Signed-off-by: Henrique Moody <henriquemoody@gmail.com>
2018-08-22 19:10:20 +02:00