Closed JDGrimes closed 6 years ago
Any other errors will be output by system()
, they just won't result in outright failure.
Note also, that as far as install goes, as of #14 we will get a failure like this in some cases anyway:
$ phpunit
Not running extension install/uninstall tests... To execute these, use -c phpunit.uninstall.xml.dist.
Installing...
Running as single site... To run multisite, use -c tests/phpunit/multisite.xml
Error: Plugin activation failed for wordpoints/wordpoints.php:
- The plugin generated unexpected output.
Remote plugin installation failed with exit code 1
I just discovered a situation where unexpected output was being produced, but for some reason we weren't failing. We should check if system()
produces any output, and always fail if it does.
It is possible to catch all errors while still having them display. However, this won't include the usual backtrace from xDebug.
I think that we could use xdebug.halt_level
to do what we want.
Originally https://github.com/JDGrimes/wp-plugin-uninstall-tester/issues/18.