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
The config option collectCoverage enables a bunch of things throughout Jest. One of these is adding the built-in CoverageReporter to the list of reporters. It would be nice if there were a way to override this, and instead add a custom reporter(s) that makes use of the same data but reports it in other ways.
Motivation
My specific motivation is to experiment with a reporter that merges coverage periodically throughout the test run, rather than only at the end, to work around #14287. In principle, everything I need to change is accessible from the existing reporter extension point. But there's no way to enable coverage collection without the default coverage reporter.
In general, this seems like it could be useful for reporting the coverage in a different format -- for example perhaps we want to use some coverage technique not supported by Istanbul.
Example
(see specific motivation)
Pitch
This seems like a way to allow improvements outside of jest with minimal new API surface. The coverage reporter is already complicated enough; right now something like #14287 can only be solved in jest itself. The API surface all already exists; one could already use the same APIs to add an additional coverage reporter. So this seems net-valuable.
The text was updated successfully, but these errors were encountered:
This issue was closed because it has been stalled for 30 days with no activity. Please open a new issue if the issue is still relevant, linking to this one.
This issue has been automatically locked since there has not been any recent activity after it was closed. Please open a new issue for related bugs.
Please note this issue tracker is not a help forum. We recommend using StackOverflow or our discord channel for questions.
🚀 Feature Proposal
The config option
collectCoverage
enables a bunch of things throughout Jest. One of these is adding the built-inCoverageReporter
to the list of reporters. It would be nice if there were a way to override this, and instead add a custom reporter(s) that makes use of the same data but reports it in other ways.Motivation
My specific motivation is to experiment with a reporter that merges coverage periodically throughout the test run, rather than only at the end, to work around #14287. In principle, everything I need to change is accessible from the existing reporter extension point. But there's no way to enable coverage collection without the default coverage reporter.
In general, this seems like it could be useful for reporting the coverage in a different format -- for example perhaps we want to use some coverage technique not supported by Istanbul.
Example
(see specific motivation)
Pitch
This seems like a way to allow improvements outside of jest with minimal new API surface. The coverage reporter is already complicated enough; right now something like #14287 can only be solved in jest itself. The API surface all already exists; one could already use the same APIs to add an additional coverage reporter. So this seems net-valuable.
The text was updated successfully, but these errors were encountered: