Closed garak closed 8 years ago
Yes nice idea :wink:
I checked a bit and for me the SymfonyTestListener
(https://github.com/symfony/symfony/blob/master/src/Symfony/Bridge/PhpUnit/SymfonyTestsListener.php) is not automatically registered. Its never instantiated/called for my TestSuite.
In the docs it says "... it automatically registers a PHPUnit event listener ..." (https://symfony.com/doc/current/components/phpunit_bridge.html#usage).
Maybe @nicolas-grekas can explain quickly how it should auto register the listener? :blush:
The trick in Symfony is to use our own phpunit bootstrapper, see https://github.com/symfony/symfony/blob/master/src/Symfony/Bridge/PhpUnit/TextUI/TestRunner.php There is no other I'm aware of, and I don't think you should take this way either...
Thanks for the fast reply @nicolas-grekas! But then the listener is not automatically registered for user symfony applications by simply requiring the bridge via composer, right?
I'm not really an expert of PHPUnit, but I see that Symfony's bridge is able to auto-register its listener. Maybe the same could be done here? Saving the user from manually editing their own PHPUnit config file.