Skip to content

Commit 3ef26d8

Browse files
authored
build(243): fix build failures from rider failing to resolve test framework (#5385)
Force resolve 243.21565.192 -> 243.21565.193 ``` org.gradle.internal.resolve.ModuleVersionNotFoundException: Could not find any version that matches com.jetbrains.intellij.java:java-test-framework:{strictly [243, 243.21565.192]; prefer 243.21565.192}. Versions that do not match: - 243.24978.46 - 243.23654.189 - 243.23654.153 - 243.23654.117 - 243.22562.218 - + 124 more ```
1 parent b72f78b commit 3ef26d8

File tree

1 file changed

+21
-2
lines changed

1 file changed

+21
-2
lines changed

plugins/toolkit/jetbrains-rider/build.gradle.kts

Lines changed: 21 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -48,15 +48,34 @@ sourceSets {
4848
}
4949
}
5050

51+
// FIX_WHEN_MIN_IS_251
52+
// org.gradle.internal.resolve.ModuleVersionNotFoundException:
53+
// Could not find any version that matches com.jetbrains.intellij.platform:test-framework:{strictly [243, 243.21565.192]; prefer 243.21565.192}.
54+
if (providers.gradleProperty("ideProfileName").get() == "2024.3") {
55+
configurations.all {
56+
resolutionStrategy.dependencySubstitution {
57+
listOf(
58+
"com.jetbrains.intellij.java:java-test-framework",
59+
"com.jetbrains.intellij.platform:test-framework",
60+
"com.jetbrains.intellij.platform:test-framework-junit5"
61+
).forEach {
62+
substitute(module(it))
63+
.using(module("$it:243.21565.193"))
64+
.because("Rider 2024.3.0 requires a newer version of test-framework")
65+
}
66+
}
67+
}
68+
}
69+
5170
dependencies {
5271
intellijPlatform {
5372
localPlugin(project(":plugin-core"))
5473
testFramework(TestFrameworkType.Bundled)
5574

56-
// https://github.com/JetBrains/intellij-platform-gradle-plugin/issues/1774
75+
// FIX_WHEN_MIN_IS_251: https://github.com/JetBrains/intellij-platform-gradle-plugin/issues/1774
5776
when (providers.gradleProperty("ideProfileName").get()) {
5877
"2023.3", "2024.1" -> {}
59-
else -> {
78+
"2024.2", "2024.3" -> {
6079
bundledModule("intellij.rider")
6180
}
6281
}

0 commit comments

Comments
 (0)