We have a curious situation where we run server-side tests (Node.js) with Mocha and client-side tests with Karma using Mocha output. These steps run independently, and each create an Istanbul coverage JSON file. We then execute istanbul report html and the JSON files are combined and the result is an HTML report. The trouble is that this HTML report contains absolute file names in the inner HTML of the a element, whereas if one executes (e.g.) istanbul cover --report html, relative paths are used.
Single report example:

Combined report example:

Is there perhaps a solution to this problem? My only viable option right now would be to post-process the HTML using e.g. sed to strip the paths. I have searched for similar issues, but couldn't find any. I also couldn't find anything applicable in the configuration settings.
Something I've noticed since I've logged this, is that e.g. navigating into ./public/javascripts on the report, would not take you to the correct location when then clicking on All files: The coverage files are in src/coverage, but the link points to just coverage. Navigating into the other pages (the links starting with Users) they all use the correct "home" link.
I'm running into a similar issue. Was this ever resolved?
+1
+1
Most helpful comment
I'm running into a similar issue. Was this ever resolved?