istanbuljs / babel-plugin-istanbul

A babel plugin that adds istanbul instrumentation to ES6 code
BSD 3-Clause "New" or "Revised" License
616 stars 72 forks source link

coverage report showing wrong results #249

Closed AishuGit closed 4 years ago

AishuGit commented 4 years ago

I updated version for babel-plugin-istanbul from "^5.1.1" to "^6.0.0" .I didn't have any issue with passing of test cases but noticed this is giving me wrong coverage report.

with version ^5.1.1 my coverage report looks like 5 1 screensshot

with version ^6.0.0 my coverage report look like 6 0 screenshot

there is a difference in coverage for number of lines covered, classes,branches and etc..so I downgraded my version to 5.1.2 which is working as expected.

I am not sure why 6.0.0 version is not considering many of the things in coverage report?

Thanks!

coreyfarrell commented 4 years ago

You have not given any details of your project so it is impossible for me to answer.

AishuGit commented 4 years ago

my actual issue is updating to 6.0.0 coverage was not shown for .js files. but I resolved this by updating .nycrc file extension with .js. Thank you foe checking though. closing this issue.