Description
I am experiencing incorrect code coverage when using JaCoCo version 0.8.13 with Kotlin data classes that utilize kotlinx.serialization. It appears that generated parameters and functions are not properly excluded from coverage, which leads to incorrect results.
This issue did not occur in version 0.8.12, where the coverage was reported correctly.
Steps to Reproduce:
gradle version: 8.12.1
kotlin version: 2.1.10
Use Kotlin data classes with kotlinx.serialization
Run JaCoCo with version 0.8.13
Example data class:
@Serializable
data class User(
@SerialName("name")
val name: String? = null,
@SerialName("age")
val age: Int? = null
)
Expected behavior:
Generated serialization-related code should be excluded from the coverage report, as it was in version 0.8.12
Actual Behavior:
The report includes functions and constructors that should be excluded or covered
Coverage for these generated elements is reported as 0%
Metadata
Metadata
Assignees
Labels
Type
Projects
Status