-
-
Notifications
You must be signed in to change notification settings - Fork 108
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
Missing coverage for multiline bash arrays and named pipes #363
Comments
Hadn't found the issue when searching, thanks for pointing me to it. |
Unfortunately, there isn't really a conclusive list of improper results. One way would be to add it to one of the scripts in tests, which gets run in the CI tests. That would be a good way of asserting that it works properly with a real parser. I haven't looked more at shfmt, but I agree it would be a cumbersome way of implementing it. Closing this since I think it's best to implement as a part of #145, although I can't really say when/if I'll work on that one. I'm personally mainly using kcov for compiled code and sometimes python, so I'm not actively bothered by the bash bugs. |
Tested on a CentOS 8 container with kcov tag pre-v40
As said in the title, kcov fails to detect usage of multiline arrays and named pipes in bash if they span multiple lines. What seems to happen is that the usage is detected but only attributed to the closing parenthesis' line.
Can be seen with this test file, which yields a 44.4% coverage rate instead of the expected 100%:
The text was updated successfully, but these errors were encountered: