Description
Description
If you work as a developer of Symfony applications, try to answer this question honestly:
When do you work on resolving direct/indirect deprecations in your project?
(1) Almost never. Just when preparing to upgrade the Symfony version.
(2) Randomly, from time to time.
(3) Most of the time. Always.
My own experience is (1) and my guess is that (1) is also the answer for most developers.
When running tests with ./vendor/bin/simple-phpunit
I see things like this (some parts use an unintelligible font for privacy reasons):
I love deprecations and the system created by @nicolas-grekas for Symfony is stunning. All PHP projects should use something like this. It's super useful when fixing deprecations.
The problem is that the output of tests is optimized for (3) (people fixing or caring about deprecations all the time), whereas most people are probably in (1) (I only care about deprecations very occasionally, when upgrading Symfony). That's why I think it's annoying to display this long list of deprecations that move the PHPUnit output too far.
A posible solution would be to have an output like this one:
Tests would always remind you about pending deprecations to fix, but wouldn't list them whenever you run tests.
This proof-of-concept prototype mentions that you should run simple-phpunit -v
to see deprecations. But we could solve this in other ways such as creating a dedicated command to display deprecations.
So, what do you think? Thanks!