You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
In a gradle multi project running a subproject 'check' task trigger all tests from all projects.
No verification rules are added to 'koverVerify' task.
The documentation said: "if verification rules are added, then running tasks koverVerify or check will trigger the execution of all active tests from all projects!"
If no verification rules are added, then the 'koverVerify' task will be disabled (skipped), but it depends on all tests and 'check' task depends on 'koverVerify', so despite the 'koverVerify' is skipped it forces gradle to run all tests from all projects.
The text was updated successfully, but these errors were encountered:
Hi,
by default koverVerify task depends only on test tasks of it's project. If the task was started with a command like :subproject:check or :subproject:koverVerify then only the test tasks of the project subproject will be triggered.
This behavior can be changed only if you configure the Kover accordingly: it is enough to set the value for the flag runAllTestsForProjectTask to true, eg
// in build.gradle.kts or build.gradle file of the root project
kover {
// other settings
runAllTestsForProjectTask = true
}
To better understand your issue, could you clarify the version of the plugin, the structure of the project and which command you run the checks with.
By default, for the task koverVerify coverage is calculated only for the tests of the one project. If classes or functions are called from tests of another module, then you need to set a flag runAllTestsForProjectTask for KoverExtension to true (see).
In this case, if verification rules are added, then running tasks koverVerify or check will trigger the execution of all active tests from all projects!
In a gradle multi project running a subproject 'check' task trigger all tests from all projects.
No verification rules are added to 'koverVerify' task.
The documentation said:
"if verification rules are added, then running tasks koverVerify or check will trigger the execution of all active tests from all projects!"
If no verification rules are added, then the 'koverVerify' task will be disabled (skipped), but it depends on all tests and 'check' task depends on 'koverVerify', so despite the 'koverVerify' is skipped it forces gradle to run all tests from all projects.
The text was updated successfully, but these errors were encountered: