DEV Community

Discussion on: Fix Symfony tests with PHPUnit 10

Collapse
 
simonjamain profile image
simonjamain

Thank you for code, it helps, but there is one important thing missing that got us quite confused :

The command line exit code was always 0 no matter what, which break the backward compatibility (and out CI/CD). As a matter of fact, the return code is return by the run method so you just have to wrap your line with and exit() :

You should IMHO make the Following change to your provided code :

exit((new \PHPUnit\TextUI\Application())->run($GLOBALS['argv']));

Thank you again !

Collapse
 
manuelcanga profile image
Manuel Canga

You're right. Thanks you for fixing my code!