-
Notifications
You must be signed in to change notification settings - Fork 7
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
[Question] Odd coverage of catch
#41
Comments
In the other news, I just managed to generate and upload Codacy native coverage report. Now I use Would you be interested to land a PR implementing experimental Codacy native coverage report? Uploading via API endpoint is somewhat tricky, that’s why I call it experimental. But the code itself is trivial: https://github.com/tstyche/tstyche/blob/271f1632e724503d8affbc425707de9d0ca6f59d/scripts/merge-coverage-reports.js#L10 |
It could be an incorrect position conversion with sourcemap.
The position in the V8 coverage data should be based on
I'm interested in is that Codacy can support this feature: codacy/codacy-coverage-reporter#506 |
😂 sounds reasonable, but I don't think it's possible to cover part of the word. |
Ah.. I missed those pink marks in the report. Indeed it is a mapping issue. To be honest, I don’t like this |
Minor problem. I noticed one
catch
marked as partially covered:Context.
fs.watch
is asynchronous api, hencesignal
is passed to it. Aborting the signal is the only way to close the watcher. That’s whyAbortError
is ignored in thecatch
block.As you see code within the
catch
block is executed, but why it is marked as partially covered?Hm.. or this is because of that
for await
loop? I mean, thetry
block is never executed till the end, because the loop is infinite. The execution can only jump tocatch
straight fromfor await
. That could explain why there is partial mark.The text was updated successfully, but these errors were encountered: