kotest-core / io.kotest.core.extensions / DiscoveryExtension

DiscoveryExtension

interface DiscoveryExtension : Extension

Allows interception of the discovery phase of Kotest.

The discovery phase is the part of the test cycle that finds Spec classes on the classpath.

This extension is only usable on the JVM target.

Note: If multiple DiscoveryExtensions are registered, the order in which they execute is not specified.

Functions

afterScan

Invoked as soon as the scan phase has completed. At this point, the Spec classes have been detected, but not yet instantiated or executed.

abstract fun afterScan(classes: List<KClass<out Spec>>): List<KClass<out Spec>>

Inheritors

IgnoredSpecDiscoveryExtension

object IgnoredSpecDiscoveryExtension : DiscoveryExtension

TagFilteredDiscoveryExtension

Allows include / exclude Spec with Tags annotation.

object TagFilteredDiscoveryExtension : DiscoveryExtension