phpro / grumphp

A PHP code-quality tool
MIT License
4.14k stars 430 forks source link

Check config before skipping #842

Closed dhaarbrink closed 3 years ago

dhaarbrink commented 3 years ago

This adds a check on the 'use_grumphp_paths' config before skipping so this task runs even though there are no changed files when use_grumphp_paths is set to false.

Q A
Branch master for features and deprecations
Bug fix? yes
New feature? no
BC breaks? yes
Deprecations? no
Documented? no
Fixed tickets -

New Task Checklist:

veewee commented 3 years ago

Thanks for the PR! It makes sense to do it like this.

Can you also add a unit test covering this case? There is already a test for when there are files available, so it should be a small addition: https://github.com/phpro/grumphp/blob/master/test/Unit/Task/PhpStanTest.php#L192

Landerstraeten commented 3 years ago

@veewee Can you check if I have added the correct unit test?

Landerstraeten commented 3 years ago

@dhaarbrink Thank you!