-
-
Notifications
You must be signed in to change notification settings - Fork 2.2k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Unexpected error code #5199
Comments
I understand that this is unexpected to you, but to me it is not ;-) Let me explain. There are different types of warnings:
The It is intentional that warnings from PHPUnit itself always lead to a shell exit code that indicates failure. |
Is it correct then that the |
Good afternoon @sebastianbergmann I have the same question. Sorry. Maybe I didn' understand something and would like to understand how to configure If I understand correctly, having one or more report types in the block forces me to use xdebug/pcov? Do I have to change the phpunit.xml settings or install xdebug/pcov? Is there an option to ignore the PHPUnit warning message? I really appreciate any help you can provide. |
I explained this in #5199 (comment): it is intentional that warnings from PHPUnit itself always lead to a shell exit code that indicates failure.
If you want a code coverage report then you need a code coverage driver, PCOV or Xdebug, installed and enabled. This is explained in the documentation.
No. |
In my experience, there actually is a way to ignore the "No code coverage driver available" warning: run the tests with the Just posting this here for anyone still looking for a solution to this particular part of the issue. |
Summary
The problem can be summarized by this output:
As you can see PHPUnit runs with no errors, but with a warning and the exit code is 1. I haven't enabled the
failOnWarning
flag in my configuration, so I find this behaviour weird.Output of
composer info | sort
The text was updated successfully, but these errors were encountered: