-
-
Notifications
You must be signed in to change notification settings - Fork 377
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
Code coverage appears broken on HHVM #365
Comments
I do not use HHVM myself and don't have the time to follow it's development. I was told that If the HHVM community wants code coverage support in PHPUnit / PHP_CodeCoverage then it is up to the HHVM community to provide patches. |
I also cann't run code coverage on hhvm: https://travis-ci.org/Koc/Sphinxy/jobs/73683002 |
Adding "it also does not work for me" comments does not help. I have nothing to add to what I wrote in #365 (comment), sorry. |
Let's wrap call of |
No clue what you're talking about. Since sebastianbergmann/environment@3e39374 and 0edb5c6 PHP_CodeCoverage won't try to use |
@Koc Please discuss pull requests such as #366 here first. You may start by commenting on what I wrote in #365 (comment). I doubt that your changes in 5ebf085 have any effect due to sebastianbergmann/environment@3e39374 and 0edb5c6. |
I ran a configuration which used to not generate errors ( At that point in time,
After looking a bit on the Internet, it appears that you have to use
|
Which versions of php-code-coverage and environment did you run your tests with? |
|
Do I understand you correctly that code coverage works on HHVM by HHVM exposing Xdebug's API when |
No. It does not work. As you can see there is no message such as
being outputted. All that |
Looking at the code, it appears that At that point, if I force it to return true, I get a similar error to what @Koc reported.
Then, forcing
My suggestion (after testing it out) is to merge @Koc #366 and my PR sebastianbergmann/environment#9. |
sebastianbergmann/environment#9 has been merged and a new release of Hopefully tonight (~ 12 hours from now) or tomorrow (~ 24 hours from now) I will have the time to review and merge #366. Thanks for your effort and patience. |
Turns out I had a bit more time to spend on this right now :-) Please test the current state and provide feedback, especially when things are broken. Thanks! |
Looks good to me 👍. hhvm @ 3.5.0 For code coverage to work on travis, one needs to make sure to enable it (as it is not enabled by default it seems): |
Hi,
I use to have phpunit running with code coverage under 4.7.7 and not report any error. Although I cannot confirm if it did indeed produce meaningful output (since it was only executed on travis and sending the report to scrutinizer-ci), my guess is that it did.
However, it appears that changes that have been done in 2.2.x might have broken what used to not generate errors.
My guess would be that the change 245f47c#diff-b2fbc27b0e544bbffcdfba89b3fb1dd4L99 changed the condition just enough to break.
It changed from
PHP_SAPI === 'phpdbg'
(such that it would use phpdbg) to!$this->isHHVM() && PHP_SAPI === 'phpdbg';
. Thus, it prevents the use of the phpdbg driver and defaults to xdebug, which isn't supported by hhvm.Here's an example callstack of the issue.
The text was updated successfully, but these errors were encountered: