karma-coverage icon indicating copy to clipboard operation
karma-coverage copied to clipboard

All errors fail at line #9 with karma-coverage enabled

Open jdivock opened this issue 11 years ago • 8 comments

I've noticed with karma-coverage enabled all jasmine errors always point to line #9 due to parsing the istanbul minified code and reporting the error from there rather than the original source code.

Error: Expected 'ctrl-states: favorites' not to be 'ctrl-states: default'.
    at null.<anonymous> (/Volumes/Site/State.ctrl.spec.js:9:2110)

The only way around this is to disable coverage whenever I need to debug where an error is failing in the controller. Is there any way around this or has some one worked out a solve? I've been unable to track one down on my own. Thanks.

jdivock avatar Aug 12 '14 14:08 jdivock

+1

andrew-luhring avatar Oct 11 '14 16:10 andrew-luhring

:+1:

mebibou avatar Oct 30 '14 15:10 mebibou

+1 this bug makes debugging impossible. I've disabled coverage reporting for my watch configuration so I can debug effectively.

lazd avatar Nov 06 '14 22:11 lazd

This is due to istanbul. I've filed a bug on their repo https://github.com/gotwarlost/istanbul/issues/274

NiGhTTraX avatar Dec 15 '14 12:12 NiGhTTraX

+1000. This definitely makes debugging difficult.

abobwhite avatar Aug 13 '15 18:08 abobwhite

+1

McTalian avatar Mar 10 '16 02:03 McTalian

+1

varunis avatar Jun 08 '16 17:06 varunis

+1

lupelius avatar Aug 12 '16 14:08 lupelius