Bug: Wrong Code Coverage for JSX #267
Labels
create-plugin
related to the create-plugin tool
released
This issue/pull request has been released.
type/bug
Something isn't working
Which package(s) does this bug affect?
Package versions
What happened?
After migration from
@grafana/toolkit
to the new plugin tools. The same code has less coverage that had before. It seems that some issue with coverage tool or jest config exists. The problem is related to alljsx/tsx
files.Coverage with default
/.config/jest.config
file (wrong coverage)100% Statements 63/63
97.01% Branches 65/67
100% Functions 13/13
100% Lines 53/53
Way to fix the issue:
Adjusted
/.config/jest.config
fileCoverage with adjusted jest config (correct coverage)
100% Statements 56/56
100% Branches 51/51
100% Functions 11/11
100% Lines 52/52
What you expected to happen
Code coverage for JSX is the same for the same code. Code coverage highlights uncovered lines correctly.
How to reproduce it (as minimally and precisely as possible)
Environment
Additional context
Tests packages versions
The text was updated successfully, but these errors were encountered: