isApplicable

open override fun isApplicable(kotlinCompilation: KotlinCompilation<*>): Boolean(source)

Test sources are never published, so they carry no API contract to watch. The Kotlin Gradle plugin already keeps explicit API mode off for test compilations, which is enough for the usual kotlin { explicitApi() } setup, but a raw -Xexplicit-api flag added to every compilation would otherwise turn the checks on there too. Skipping the compiler plugin for test compilations makes the exclusion hold whichever way explicit API mode is enabled.