[feature request] provide per-test coverage map
- Dominant language
- JavaScript
- Stars
- 2.1k
- Forks
- 99
- PR merge metrics
- No merged PRs in 30d
Description
Main motivation for this feature is to provide the necessary data required to implement IDE feature - instant feedback to user, which line in code has failed which test(s).
Similar to Visual Studio Live Testing:

Is there a way to communicate what is the context of current code coverage execution, for example, populate lcov TN (Test Name)?
If not, can you recommend how to handle this info from the test runner: Maybe execute tests one by one and save coverage separately? But wouldn't this cause performance / coverage map merge problems?
PS istanbul does not support this [feature](https://github.com/istanbuljs/nyc/issues/633), and seems this will not be implemented anytime soon
Contributor guide
Research direction
The issue names no files, tests, or entry points. Start by tracing c8's coverage execution and report-generation path, then investigate how per-test context could be represented in lcov data. Done means c8 exposes a reliable per-test line coverage map suitable for IDE feedback without unresolved merge or performance concerns.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- javascript, node.js
- Domain
- developer-experience, testing
- Issue type
- Feature
- Difficulty
- 5/5
- Estimated time
- Over a week
- Activity status
- Stale
- Clarity
- Needs clarification
- Newbie friendliness
- 20/100