Open sweetim opened 8 years ago
Looks like istanbul is not counting arrow functions as "functions". This should be easy to fix but I'm in he middle of a refactor so I can only get to it later.
Thanks for reporting this issue.
@sweetim I had same error. But in my case root of the problem was damn stupid. I just forgot to remove describe.only from one of my tests! =))) I thought it may help you.
The issue still exists with istanbul@0.4.5
. Any update?
Istanbul's inability to cover arrow functions is causing me to do some frustrating refactoring. Do we have any updates on this?
You could use nyc
package
https://www.npmjs.com/package/nyc
this problem has been resolved with that package! ;)
@sweetim it should be a native function from Istanbul instead using another package.
Any updates?
Updates on this issue?
Still active
As stated in the readme, this version of Istanbul has been deprecated, 5 years ago already. Use https://github.com/istanbuljs/nyc @gotwarlost why don't you put this repo into read-only mode?
As stated in the readme, this version of Istanbul has been deprecated, 5 years ago already. Use https://github.com/istanbuljs/nyc @gotwarlost why don't you put this repo into read-only mode?
Sorry!
I have a module that I would like to have code coverage using
Istanbul
, but I cant get it working when I use arrow function.my module
compute.js
and my unit test code
test.js
When i run this command
I get my coverage summary shown below:
In my Function row, i am getting 0/0, if i change my
compute.js
to use function call.now, i am getting the correct code coverage
package.json
May i know why the arrow function is not working and how can I fix them?