-
Notifications
You must be signed in to change notification settings - Fork 5.2k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
fix(cli): ensure empty lines don't count towards coverage #11957
Conversation
One known issue, empty lines in transpiled source don't map well.
Main issue here is that range[0] which is the evaluation range gets expanded to include everything. This in turn marks non-executable lines inside the extended range as executable even when they are not.
All of the mapping and lookups in this is a prime candidate to make use of the denoland/deno_ast utilities (in a follow up). |
2359fb8
to
2788e8a
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM, thank you and sorry it took so long to land.
…noland#11957)" This reverts commit d5b38a9.
…noland#11957)" (denoland#12348) This reverts commit d5b38a9.
Since this PR has been reverted, is there any other PR/work in progress to fix coverage that we can follow? |
Unfortunately not |
This cleans up coverage by computing the result ahead of time and passing that as-is into the reporter(s).
Doing so, I made sure to throw out empty lines.
Fixes #11327