Closed hirrolot closed 1 year ago
Well, it turns out that when I actually use functions from lib/
inside the tests, everything works perfectly. It's still, however, very confusing, and I don't know whether it's intended or not. With empty tests, I'd rather expect to see 0% test coverage.
I think this is due to what's described in #136, #391 (I just encountered a similar issue and was looking for answers, too).
Perhaps the Error: no *.coverage files found
message can include some hints as to what the cause can be, and the files not being linked into the project will be one of the hints.
It's difficult for Bisect to, in a general way, know that you might have files that have not been linked into the build of the test suite (what I meant by project above), but Bisect can make an effort to warn users about that in various places.
I have the following project structure:
Inside
lib/dune
:Inside
test/dune
:I expect
bisect_ppx
to do test coverage of mylib
. However, when I execute the following commands:I obtain
Error: no *.coverage files found
.What am I doing wrong? I think that
bisect_ppx
just doesn't see theinstrumentation
clause insidelib/dune
. If I add the same clause intest/dune
, it will generate test coverage (but rather uselessly -- for the tests themselves).