When running coverage against babel es2015 source code, highlighting is completely off.
It seems to start perhaps in the correct position, but the end of the highlighting is off.
Here is an annotated screenshot of the issue:
http://imgur.com/xXFWjtp
I've the same issue. Highlighting is incorrect when using Babel 6.5 to transpile ES2015 to ES5, and even ES5 to ES5 (i.e. running Babel over already compiled sources). Example:


@skozin as a temporary solution... I changed the css so that .no-branch has a left border of 10px solid red... instead of a background color... This way you only see highlighting at the start of the missed coverage.
hacky but works.
@cphoover, thanks, interesting hack. I'll try it =)
BTW, I've found that, in my case, the issue is probably related not to istanbul itself, but to nyc, which is a coverage tool built on istanbul that works for apps with subprocesses. See this issue: https://github.com/bcoe/nyc/issues/198.
I also advocate that Babel's workaround code will not be tested. Example:

@julmot, +1, but probably the only way to do this is to use info from sourcemaps to see whether the specific part of generated code maps to some location in the sources, and exclude it from report if not (i.e. don't highlight it and don't count in covered/total functions/branches/statements/lines numbers).
Probably this can be done only on function level, as Babel only generates helpers in form of functions. On the other hand, Babel uses regenerator to transpile generators and async/await functions, and regenerator produces statements that cannot be mapped to the original source.
But I would be happy even if Istanbul covered only the non-generator case.
See also: #582, https://github.com/bcoe/nyc/issues/198#issuecomment-202340306.
@cphoover Agreed. This appears to just be proble with utilizing the background css attribute and the container structure. If you favor border vs background the correct areas are highlighted
Most helpful comment
@skozin as a temporary solution... I changed the css so that .no-branch has a left border of 10px solid red... instead of a background color... This way you only see highlighting at the start of the missed coverage.
hacky but works.