Ignore native bundle artifacts in ArtifactsTest
* kotlin-native not enabled by default in project
This commit is contained in:
committed by
Space Team
parent
112473f310
commit
555e374a33
@@ -27,6 +27,15 @@ class ArtifactsTest {
|
|||||||
private val localRepoPath = Paths.get(mavenLocal, "org/jetbrains/kotlin")
|
private val localRepoPath = Paths.get(mavenLocal, "org/jetbrains/kotlin")
|
||||||
private val expectedRepoPath = Paths.get("repo/artifacts-tests/src/test/resources/org/jetbrains/kotlin")
|
private val expectedRepoPath = Paths.get("repo/artifacts-tests/src/test/resources/org/jetbrains/kotlin")
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Kotlin native bundles are present in TC artifacts but should not be checked until kotlin native enabled project-wide
|
||||||
|
*/
|
||||||
|
private val nativeBundles = setOf(
|
||||||
|
"kotlin-native",
|
||||||
|
"kotlin-native-compiler-embeddable",
|
||||||
|
"kotlin-native-prebuilt",
|
||||||
|
)
|
||||||
|
|
||||||
private val excludedProjects = setOf(
|
private val excludedProjects = setOf(
|
||||||
"android-test-fixes",
|
"android-test-fixes",
|
||||||
"annotation-processor-example",
|
"annotation-processor-example",
|
||||||
@@ -37,9 +46,6 @@ class ArtifactsTest {
|
|||||||
"kotlin-gradle-subplugin-example",
|
"kotlin-gradle-subplugin-example",
|
||||||
"kotlin-java-example",
|
"kotlin-java-example",
|
||||||
"kotlin-maven-plugin-test",
|
"kotlin-maven-plugin-test",
|
||||||
"kotlin-native",
|
|
||||||
"kotlin-native-compiler-embeddable",
|
|
||||||
"kotlin-native-prebuilt",
|
|
||||||
"org.jetbrains.kotlin.fus-statistics-gradle-plugin.gradle.plugin",
|
"org.jetbrains.kotlin.fus-statistics-gradle-plugin.gradle.plugin",
|
||||||
"org.jetbrains.kotlin.gradle-subplugin-example.gradle.plugin",
|
"org.jetbrains.kotlin.gradle-subplugin-example.gradle.plugin",
|
||||||
"org.jetbrains.kotlin.test.fixes.android.gradle.plugin",
|
"org.jetbrains.kotlin.test.fixes.android.gradle.plugin",
|
||||||
@@ -53,8 +59,10 @@ class ArtifactsTest {
|
|||||||
val expectedPomPath = actual.toExpectedPath()
|
val expectedPomPath = actual.toExpectedPath()
|
||||||
DynamicTest.dynamicTest(expectedPomPath.fileName.toString()) {
|
DynamicTest.dynamicTest(expectedPomPath.fileName.toString()) {
|
||||||
if ("${expectedPomPath.parent.fileName}" !in excludedProjects) {
|
if ("${expectedPomPath.parent.fileName}" !in excludedProjects) {
|
||||||
val actualString = actual.toFile().readText().replace(kotlinVersion, "ArtifactsTest.version")
|
if ("${expectedPomPath.parent.fileName}" !in nativeBundles) {
|
||||||
assertEqualsToFile(expectedPomPath, actualString)
|
val actualString = actual.toFile().readText().replace(kotlinVersion, "ArtifactsTest.version")
|
||||||
|
assertEqualsToFile(expectedPomPath, actualString)
|
||||||
|
}
|
||||||
} else {
|
} else {
|
||||||
if (isTeamCityBuild) fail("Excluded project in actual artifacts: $actual")
|
if (isTeamCityBuild) fail("Excluded project in actual artifacts: $actual")
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user