View Issue Details

IDProjectCategoryView StatusLast Update
0001027XdebugUncategorizedpublic2014-03-05 09:33
ReporterTominator Assigned Toderick  
PrioritynormalSeveritymajorReproducibilityalways
Status resolvedResolutionno change required 
Platformx64OSWindowsOS Version8
Product Version2.2.3 
Summary0001027: Code coverage doesn't work when dealing with PEAR
Description

Hi,
I have a project that uses the PEAR MDB2 package for database access. When I run phpunit with code coverage, I get output, but none of my classes are included. It might be a problem with phpunit, or with xdebug.
When I remove the PEAR dependency for testing, the coverage output is correct (all my classes are included)

Steps To Reproduce

I made a small project (attached).

Now, inside the "coverage" folder (also in the example zip attached) you see my output: C\xampp\php\pear (with nothing in it) and E\Temp\coveragetest\libs with nothing in it.

When you now go to the file tests\unit\libtests\CalculatorTest.php and you remove the "require" line on top, and re-run phpunit_unit.bat, you will see in the coverage directory that a new directory is made: libs\ and that it contains Calculator.php information.

Additional Information

Thanks for any info!

TagsNo tags attached.
Attached Files
coveragetest.zip (466,469 bytes)
Operating SystemWindows 8 x64
PHP Version5.4.7

Activities

Tominator

2014-01-28 10:23

reporter   ~0002670

I upgraded my xampp this weekend, and guess what, now coverage is generated successfully. Maybe it was related to the phpunit coverage module that also updated, I don't know.
At the moment, the generated HTML is no longer split up in C and E folders. Maybe it's because I installed the new xampp to my E drive, together with my test project, so it didn't need to create the extra folders...?
This issue may have low priorty, because I've no idea which software caused it, but thanks for reading anyway!

derick

2014-03-05 09:33

administrator   ~0002754

Glad to know that it works now. I'm closing this issue out, but feel free to reopen if this returns. Right now, I've no idea what could cause this and as it works, it makes little sense to spend time on it.

Issue History

Date Modified Username Field Change
2014-01-24 16:55 Tominator New Issue
2014-01-24 16:55 Tominator File Added: coveragetest.zip
2014-01-28 10:23 Tominator Note Added: 0002670
2014-03-05 09:33 derick Note Added: 0002754
2014-03-05 09:33 derick Status new => resolved
2014-03-05 09:33 derick Resolution open => no change required
2014-03-05 09:33 derick Assigned To => derick
2016-07-31 12:36 derick Category Usage problems => Usage problems (Crashes)
2016-07-31 12:38 derick Category Usage problems (Crashes) => Usage problems (Wrong Results)
2020-03-12 16:35 derick Category Usage problems (Wrong Results) => Variable Display
2020-03-12 16:38 derick Category Variable Display => Uncategorized