Jasmine or Node.js or npm coverage reporting?

I'm using RubyMIne for node development at the moment and am trying to figure out how to get the coverage reporting to show up when launching through any of these three plugins: Jasmine, Node.js or npm. I am using Jasmine for unit testing and nyc (istanbul) for coverage and all three plugins do fine generating the lcov coverage reports. The only problem is that the little "code coverage" feature seems disabled with all three of those configuration tools.

The icon shows up when launching with Karma, but I'm not using Karma so would prefer not need to install another set of packages for this.

I have been configuring nyc to also product html reports, but I much prefer to use the integrated coverage browser in RubyMine.

Any suggestions? Would this work in WebStorm as it is a more javascript-focused environment? I'm looking for some advice for a noob in this area.


Comment actions Permalink

Run with coverage is only enabled for supported test runners (Karma, Mocha, Jest, ...). Loading existing coverage reports generated externally is also not supported (https://youtrack.jetbrains.com/issue/WEB-10303).

So, if you need to debug your tests or collect coverage, I'd suggest using one of test runners mentioned above.

>Would this work in WebStorm as it is a more javascript-focused environment?

No, RubyMine includes all WebStorm stuff for javaScript development, so switching to WebStorm won't make things any better

Comment actions Permalink

Thanks. I posted an issue with the Jasmine plugin to hopefully get that support added there. I didn't realize it wasn't a supported test runner, but I see it's under active development so hopefully someone familiar with it can add that functionality.




Please sign in to leave a comment.