Modify ↓
Ticket #18 (closed defect: invalid)
Missing the "else" part ...
| Reported by: | norman@… | Owned by: | |
|---|---|---|---|
| Priority: | minor | Milestone: | 2.2.0 |
| Component: | Version: | 2.2.0RC1 | |
| Keywords: | Coverage Report, missing else part | Cc: |
Description
Hi folks,
i saw this on some of my code reports this morning. Look at the folling if statment:
if (x > 0) {
foo
} else {
bar
}
The code coverage report tells me that it handled the foo-part and the bar-part and also the if-part but tells me, it doesn't cover the else-part. This will lead to wrong coverage outputs even when it is summed up.
Thanks in advance
Norman
Attachments
Change History
Note: See
TracTickets for help on using
tickets.

This is an Xdebug/Zend engine peculiarity, nothing that's (easily) fixable in the code coverage classes.