Ignore test due to the bug in AGP on Gradle 6.8+.
It is not possible to make it work via reflection.
This commit is contained in:
+11
-3
@@ -2,8 +2,8 @@ package org.jetbrains.kotlin.gradle
|
|||||||
|
|
||||||
import org.gradle.api.logging.LogLevel
|
import org.gradle.api.logging.LogLevel
|
||||||
import org.gradle.api.logging.configuration.WarningMode
|
import org.gradle.api.logging.configuration.WarningMode
|
||||||
|
import org.gradle.util.GradleVersion
|
||||||
import org.jetbrains.kotlin.gradle.util.*
|
import org.jetbrains.kotlin.gradle.util.*
|
||||||
import org.jetbrains.kotlin.test.KotlinTestUtils
|
|
||||||
import org.jetbrains.kotlin.test.util.KtTestUtil
|
import org.jetbrains.kotlin.test.util.KtTestUtil
|
||||||
import org.junit.Assume
|
import org.junit.Assume
|
||||||
import org.junit.Test
|
import org.junit.Test
|
||||||
@@ -24,8 +24,15 @@ open class KotlinAndroid36GradleIT : KotlinAndroid33GradleIT() {
|
|||||||
get() = GradleVersionRequired.AtLeast("6.0")
|
get() = GradleVersionRequired.AtLeast("6.0")
|
||||||
|
|
||||||
@Test
|
@Test
|
||||||
fun testAndroidMppSourceSets(): Unit = with(Project("new-mpp-android-source-sets")) {
|
fun testAndroidMppSourceSets(): Unit = with(
|
||||||
build("sourceSets") {
|
Project("new-mpp-android-source-sets")
|
||||||
|
) {
|
||||||
|
// AbstractReportTask#generate() task action was removed in Gradle 6.8+,
|
||||||
|
// that SourceSetTask is using: https://github.com/gradle/gradle/commit/4dac91ab87ea33ee8689d2a62b691b119198e7c7
|
||||||
|
// leading to the issue that ":sourceSets" task is always in 'UP-TO-DATE' state.
|
||||||
|
// Skipping this check until test will start using AGP 7.0-alpha03+
|
||||||
|
if (GradleVersion.version(chooseWrapperVersionOrFinishTest()) < GradleVersion.version("6.8")) {
|
||||||
|
build("sourceSets", options = defaultBuildOptions().copy(debug = true)) {
|
||||||
assertSuccessful()
|
assertSuccessful()
|
||||||
|
|
||||||
assertContains("Android resources: [lib/src/main/res, lib/src/androidMain/res]")
|
assertContains("Android resources: [lib/src/main/res, lib/src/androidMain/res]")
|
||||||
@@ -52,6 +59,7 @@ open class KotlinAndroid36GradleIT : KotlinAndroid33GradleIT() {
|
|||||||
assertContains("Java-style resources: [lib/betaSrc/freeBetaDebug/resources, lib/src/androidFreeBetaDebug/resources]")
|
assertContains("Java-style resources: [lib/betaSrc/freeBetaDebug/resources, lib/src/androidFreeBetaDebug/resources]")
|
||||||
assertContains("Java-style resources: [lib/betaSrc/freeBetaRelease/resources, lib/src/androidFreeBetaRelease/resources]")
|
assertContains("Java-style resources: [lib/betaSrc/freeBetaRelease/resources, lib/src/androidFreeBetaRelease/resources]")
|
||||||
}
|
}
|
||||||
|
}
|
||||||
|
|
||||||
build("testFreeBetaDebug") {
|
build("testFreeBetaDebug") {
|
||||||
assertFailed()
|
assertFailed()
|
||||||
|
|||||||
Reference in New Issue
Block a user