Skip to content
This repository was archived by the owner on Dec 8, 2024. It is now read-only.

Can't get coverage output #197

Open
ekirkland opened this issue Apr 29, 2014 · 5 comments
Open

Can't get coverage output #197

ekirkland opened this issue Apr 29, 2014 · 5 comments

Comments

@ekirkland
Copy link

I put istanbul into place a few weeks ago to cover our mocha tests and it's been awesome, but then all of the sudden I have noticed it is no longer producing new coverage output. When I run istanbul -v cover _mocha -- --recursive tests I get an empty coverage folder. Any ideas of how to debug this? I simplified my tests down to a single test case and the same thing happens.

@dougwilson
Copy link
Contributor

I am getting this on a new machine setup as well. The same commands that work on other machines are producing no output on this new machine. Windows 7 with node.js 0.10.28

@dougwilson
Copy link
Contributor

So I figured out my issue: I was using my command prompt within a NTFS junction and when istanbul builds the file list, it uses path.resolve(root, file) which resolves the file to the path inside my junction, but the hook just does path.resolve(file) which resolves the real path to the file, which is outside the junction and is thus not located within the fileMap :(

@yoshuawuyts
Copy link

+1 on ubuntu here. Istanbul doesn't correctly execute the --recursive flag from mocha.

@gotwarlost
Copy link
Owner

Since #219 is merged, could you please retry with the latest istanbul and see if the issue goes away?

@silkentrance
Copy link

@gotwarlost Considering the tests over at https://github.com/raszi/node-tmp which use both mocha and istanbul for coverage, everything works as expected. I believe that you can close this issue for good.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

5 participants