Skip to content

Commit c730eb3

Browse files
committed
chore(intellij): correct junit version
1 parent 121b26e commit c730eb3

File tree

2 files changed

+8
-39
lines changed

2 files changed

+8
-39
lines changed

intellij-client/build.gradle.kts

Lines changed: 7 additions & 38 deletions
Original file line numberDiff line numberDiff line change
@@ -4,13 +4,6 @@ import org.jetbrains.intellij.platform.gradle.Constants.Constraints
44
import org.jetbrains.intellij.platform.gradle.IntelliJPlatformType
55
import org.jetbrains.intellij.platform.gradle.TestFrameworkType
66
import org.jetbrains.intellij.platform.gradle.tasks.PrepareSandboxTask
7-
import java.net.URI
8-
import java.net.http.HttpClient
9-
import java.net.http.HttpRequest
10-
import java.net.http.HttpResponse
11-
import java.time.Duration
12-
import java.time.temporal.ChronoUnit
13-
import java.util.regex.Pattern
147

158
plugins {
169
alias(libs.plugins.kotlin)
@@ -53,7 +46,7 @@ dependencies {
5346
create(
5447
providers.gradleProperty("platformType"),
5548
providers.gradleProperty("platformVersion"),
56-
useInstaller = false
49+
useInstaller = false,
5750
)
5851

5952
// Plugin Dependencies. Uses `platformBundledPlugins` property from the gradle.properties file for bundled IntelliJ Platform plugins.
@@ -85,14 +78,13 @@ intellijPlatform {
8578
}
8679
}
8780

88-
val changelog = project.changelog // local variable for configuration cache compatibility
89-
// Get the latest available change notes from the changelog file
81+
val changelog = project.changelog
82+
83+
// local variable for configuration cache compatibility // Get the latest available change notes from the changelog file
9084
changeNotes = providers.gradleProperty("pluginVersion").map { pluginVersion ->
9185
with(changelog) {
9286
renderItem(
93-
(getOrNull(pluginVersion) ?: getUnreleased())
94-
.withHeader(false)
95-
.withEmptySections(false),
87+
(getOrNull(pluginVersion) ?: getUnreleased()).withHeader(false).withEmptySections(false),
9688
Changelog.OutputType.HTML,
9789
)
9890
}
@@ -112,6 +104,7 @@ intellijPlatform {
112104

113105
publishing {
114106
token = providers.environmentVariable("PUBLISH_TOKEN")
107+
115108
// The pluginVersion is based on the SemVer (https://semver.org) and supports pre-release labels, like 2.1.7-alpha.3
116109
// Specify pre-release label to publish the plugin in a custom Release Channel automatically. Read more:
117110
// https://plugins.jetbrains.com/docs/intellij/deployment.html#specifying-a-release-channel
@@ -156,6 +149,7 @@ val prepareSandboxConfig: PrepareSandboxTask.() -> Unit = {
156149

157150
tasks {
158151
runIde {
152+
159153
// From https://app.slack.com/client/T5P9YATH9/C5U8BM1MK
160154
// systemProperty("ide.experimental.ui", "true")
161155
// systemProperty("projectView.hide.dot.idea", "false")
@@ -175,7 +169,6 @@ tasks {
175169
}
176170

177171

178-
179172
// Configure UI tests plugin
180173
// Read more: https://github.com/JetBrains/intellij-ui-test-robot
181174
val runIdeForUiTests by intellijPlatformTesting.runIde.registering {
@@ -208,27 +201,3 @@ val runIdeIntellijIdeaC by intellijPlatformTesting.runIde.registering {
208201

209202
prepareSandboxTask(prepareSandboxConfig)
210203
}
211-
212-
fun fetchLatestLsp4ijNightlyVersion(): String {
213-
val client = HttpClient.newBuilder().build();
214-
var onlineVersion = ""
215-
try {
216-
val request: HttpRequest = HttpRequest.newBuilder()
217-
.uri(URI("https://plugins.jetbrains.com/api/plugins/23257/updates?channel=nightly&size=1"))
218-
.GET()
219-
.timeout(Duration.of(10, ChronoUnit.SECONDS))
220-
.build()
221-
val response = client.send(request, HttpResponse.BodyHandlers.ofString());
222-
val pattern = Pattern.compile("\"version\":\"([^\"]+)\"")
223-
val matcher = pattern.matcher(response.body())
224-
if (matcher.find()) {
225-
onlineVersion = matcher.group(1)
226-
println("Latest approved nightly build: $onlineVersion")
227-
}
228-
} catch (e: Exception) {
229-
println("Failed to fetch LSP4IJ nightly build version: ${e.message}")
230-
}
231-
232-
val minVersion = "0.0.1-20231213-012910"
233-
return if (minVersion < onlineVersion) onlineVersion else minVersion
234-
}

intellij-client/gradle/libs.versions.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
# libraries
33
annotations = "26.0.1"
44
kotlinxSerialization = "1.8.0"
5-
junit = "5.11.4"
5+
junit = "4.13.2"
66
lsp4j = "0.21.1"
77

88
# plugins

0 commit comments

Comments
 (0)