You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
coffee-coverage replaces require.extensions['.coffee'] to handle .coffee file compilations itself.
during tests, one of my submodules was requiring coffee-script/register, which led to the original coffee-script handler to compile the files, and coffee-coverage not instrumenting them.
coffee-coverage replaces require.extensions['.coffee'] to handle .coffee file compilations itself.
during tests, one of my submodules was requiring coffee-script/register, which led to the original coffee-script handler to compile the files, and coffee-coverage not instrumenting them.
I suspect that this is faced by other users as well. For example the user facing the issue #55 uses sprout which has this code https://github.com/carrot/sprout/blob/389799b5fa0eaa10e6f92d002dc1ee3ea3bc0660/lib/template.js#L21.
As you can see from the comments, when jwalton was trying to debug, the last instrumented file was a sprout.coffee.
There are two possible solutions:
I have used the first approach here https://github.com/abresas/register-coffee-coverage, a module that I use as a replacement for my mocha tests, passing --require register-coffee-coverage.
I would prefer this is fixed from coffee-coverage project itself, so I can throw away my wrapper-module .
The text was updated successfully, but these errors were encountered: