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
When the coverage map is mapped back to sources using istanbul-lib-source-maps the implicit else gets dropped in the process. Here is the line that checks whether the branch exists in sources, and simply excludes it from results. Since the implicit else does not exist in the sources, the mapping variable is falsy.
When the coverage map is mapped back to sources using
istanbul-lib-source-maps
the implicitelse
gets dropped in the process. Here is the line that checks whether the branch exists in sources, and simply excludes it from results. Since the implicitelse
does not exist in the sources, themapping
variable is falsy.istanbuljs/packages/istanbul-lib-source-maps/lib/transformer.js
Lines 71 to 85 in fb8cb4b
Example of implicit
else
just so that everyone is on the track of what this issue is about:Check the reproduction case below to see how
data.branchMap
anddata.b
loses theelse
branch.Minimal reproduction case
Requirements:
$ npm install istanbul-lib-instrument istanbul-lib-coverage istanbul-lib-source-maps esbuild $ node -v > v16.15.1
Output:
Related issues from downstream:
The text was updated successfully, but these errors were encountered: