Closed tyge68 closed 8 years ago
JSCover line coverage instruments physical lines of code rather than logical JavaScript statements; it works best with code that has exactly one statement per line. If you put multiple statements on a line, or split a line across two or more statements, you may get strange results.
Thanks, I will fix the code then myself, as JSCover is a nice tool which we could integrate easily as it is Java based, but we use it with Sonar, and many lines are missed then in the report due to above.
Currently JSCover (1.0.24) doesn't detect execution of object field value assignment as well as var on multiple lines.
Example:
or
Thus the coverage result is wrong and doesn't reflect actual reality of the code execution. Coverage will appear to be less.