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

Does babel-plugin-istanbul support jest? #252

Closed MNF closed 3 years ago

MNF commented 4 years ago

According to readme, the babel-plugin-istanbul only works with with karma-coverage and mocha on Node.js. But some issues ( e.g. https://github.com/istanbuljs/babel-plugin-istanbul/issues/95) are telling, that jest is also supported.

Can you clarify Readme.md to say which other testing tools (e.g. jest) it can be used with?

coreyfarrell commented 4 years ago

jest integrates babel-plugin-istanbul so you wouldn't need (or want) to add it on your own. See jest CLI documentation, running jest --coverage will cause jest to enable this plugin for you.

This plugin can be used with any node.js testing tool that allows use of babel transpilation but we only mention the most common in this readme (jest is not specifically mentioned because as a jest user you would not call on this plugin). We should probably have a link in the README to https://istanbul.js.org/docs/tutorials/.