Closed clickjamper closed 2 months ago
Hi, Kover notifies only that an object has been declared in the code that is not explicitly used anywhere.
Unfortunately, when compiling, the constant is not stored in the class, so Kover cannot determine exactly how this object will be used - independently or as a scope for grouping constants.
In this case, it is possible to exclude such classes from the report by name or using an annotation.
@shanshin Fixed in agent version 1.0.741
Fixed in Kover 0.7.5
I updated Kover to 0.7.5, but it still shows that an object containing only constants has no tests.
@BulatInDrive, thanks for the report! The problem is reproduced for string constants
Same issue shows that an interface containing companion object
Reproduced for companion objects
Closed in favour of https://github.com/Kotlin/kotlinx-kover/issues/583
Why do you need to write tests for classes which contains only constants like
internal object TestObject { const val TEST_CONST = "test_const" }