Skip to content

Commit

Permalink
chore: fix integration tests
Browse files Browse the repository at this point in the history
Signed-off-by: Stephane Bouchet <sbouchet@redhat.com>
  • Loading branch information
sbouchet committed Dec 18, 2024
1 parent dabbd3b commit 2d4a7cc
Show file tree
Hide file tree
Showing 3 changed files with 15 additions and 4 deletions.
6 changes: 3 additions & 3 deletions build.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -23,10 +23,10 @@ dependencies {
api(libs.remote.fixtures)
}


java {
sourceCompatibility = JavaVersion.VERSION_21
targetCompatibility = JavaVersion.VERSION_21
toolchain {
languageVersion = JavaLanguageVersion.of(21)
}
withSourcesJar()
withJavadocJar()
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -79,8 +79,13 @@ public static RemoteRobot runIde(IntelliJVersion ideaVersion, int port) {
String fileExtension = OS_NAME.contains("windows") ? ".bat" : "";
String[] platformTypeVersion = generatePlatformTypeVersion();

ProcessBuilder pb = new ProcessBuilder("." + File.separator + "gradlew" + fileExtension, "runIdeForUiTests", "-PideaVersion=" + ideaVersion, "-Drobot-server.port=" + port, "-PplatformType=" + platformTypeVersion[0], "-PplatformVersion=" + platformTypeVersion[1]);
ProcessBuilder pb = null;

if (ideaVersion.toInt() < 20242) {
pb = new ProcessBuilder("." + File.separator + "gradlew" + fileExtension, "runIdeForUiTests", "-PideaVersion=" + ideaVersion, "-Drobot-server.port=" + port);
} else {
pb = new ProcessBuilder("." + File.separator + "gradlew" + fileExtension, "runIdeForUiTests", "-Drobot-server.port=" + port, "-PplatformType=" + platformTypeVersion[0], "-PplatformVersion=" + platformTypeVersion[1]);
}
boolean isDebugOn = Boolean.parseBoolean(System.getProperty("intellij_debug", "false")); // For more info on intellij_debug please check README
if (isDebugOn) {
redirectProcessOutputs(pb);
Expand Down
6 changes: 6 additions & 0 deletions src/test-project/build.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,12 @@ group = "com.redhat.devtools.intellij"
version = "1.0-SNAPSHOT"
val platformVersion = providers.gradleProperty("ideaVersion").get()

java {
toolchain {
languageVersion = JavaLanguageVersion.of(21)
}
}

repositories {
mavenCentral()
intellijPlatform {
Expand Down

0 comments on commit 2d4a7cc

Please sign in to comment.