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
Test fixtures are included in coverage #83
Comments
To search for project classes, Kover uses all the source sets except |
Great.
This doesn't sound quite right to me - Gradle defines the test fixtures as test code. Although there are circumstances under which you might want to measure the test coverage of your test fixtures (you can optionally publish test fixtures), it's counterintuitive to combine this with the coverage of the |
Kover takes a list of project classes from all available source sets (except for |
Fair enough. I think the built-in Jacoco plugin only takes the |
Duplcates #19 *filtering of sourcesets |
Kover treats test fixtures as production code, including them in coverage reports. Test fixtures should be treated as test code.
If I add the (misleadingly named)
java-test-fixtures
plugin, along with thekotlin
andkover
plugins, Gradle will look insrc/testFixtures/kotlin
for code "used to setup the code under test, or provide utilities aimed at facilitating the tests of a component":The
testFixtures
code is explicitly test code, but if I run./gradlew koverHtmlReport
, the generated report includes any code in thetestFixtures
directory in addition to the code inmain
.I've put together a small example project illustrating the issue.
The text was updated successfully, but these errors were encountered: