KoverCurrentProjectVariantsConfig

Type for customizing report variants shared by the current project.

A report variant is a set of information used to generate a reports, namely: project classes, a list of Gradle test tasks, classes that need to be excluded from instrumentation.

currentProject {
// create report variant with custom name,
// in which it is acceptable to add information from other variants of the current project, as well as `kover` dependencies
createVariant("custom") {
// ...
}

// Configure the variant that is automatically created in the current project
// For example, "jvm" for JVM target or "debug" for Android build variant
providedVariant("jvm") {
// ...
}

// Configure the variant for all the code that is available in the current project.
// This variant always exists for any type of project.
totalVariant {
// ...
}
}

Functions

Link copied to clipboard
abstract fun copyVariant(variantName: String, originalVariantName: String)

Create custom report variant as a copy of the originalVariantName variant, however, with the new name variantName.

Link copied to clipboard
abstract fun createVariant(variantName: String, block: Action<KoverVariantCreateConfig>)

Create custom report variant with name variantName. In it is acceptable to add information from other variants of the current project, as well as kover dependencies.

Link copied to clipboard
abstract fun instrumentation(block: Action<KoverProjectInstrumentation>)

Instrumentation settings for the current Gradle project.

Link copied to clipboard
abstract fun providedVariant(variantName: String, block: Action<KoverVariantConfig>)

Configure the variant with name variantName that is automatically created in the current project. For example, "jvm" for JVM target or "debug" for Android build variant.

Link copied to clipboard
abstract fun sources(block: Action<KoverVariantSources>)

Limit the classes that will be included in the reports. These settings do not affect the instrumentation of classes.

Link copied to clipboard
abstract fun totalVariant(block: Action<KoverVariantConfig>)

Configure the variant for all the code that is available in the current project. This variant always exists for any type of project.

Properties

Link copied to clipboard

Instance to configuring of instrumentation for the current Gradle project.

Link copied to clipboard

Instance to limit the classes that will be included in the reports.