-
-
Notifications
You must be signed in to change notification settings - Fork 5.7k
Description
I'm having some trouble getting Julia to properly compute my test coverage.
A simple example of what goes wrong is in https://codecov.io/gh/Juice-jl/LogicCircuits.jl/src/257b9a792cb506329c7bb27e2ddfdedb1a097af7/src/LoadSave/vtree_line_compiler.jl
As you can see, there are functions defined inside of another function, and these are not accounted for properly. The code on line 45-48 is clearly not dead, and is actually executed in the unit tests, but not accounted for. Meanwhile the function headers on lines 44 and 50 are marked as not covered, even though they are executed during test.
Similar issues can be seen in other parts of my code that have a similar pattern: https://codecov.io/gh/Juice-jl/LogicCircuits.jl/src/257b9a792cb506329c7bb27e2ddfdedb1a097af7/src/LoadSave/circuit_line_compiler.jl
What's obviously a bug here is that some function bodies are covered, while their headers are not, which should be impossible.