Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 4 additions & 0 deletions .gitlab/upload_ciapp.sh
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,10 @@ if [ -n "$TEST_JVM" ]; then
for var in $(compgen -v JAVA_ | grep -E '^JAVA_[0-9]+_HOME$'); do
ver="${var#JAVA_}"
ver="${ver%_HOME}"
# TODO(JDK-28-EA): remove after GA (tip will move to 28)
if [ "$ver" = "28" ]; then
continue
fi
Comment thread
bric3 marked this conversation as resolved.
Resolved
if [ "$ver" -gt "$MAX_VER" ] 2>/dev/null; then
MAX_VER="$ver"
fi
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -35,6 +35,16 @@ import java.nio.file.Paths
class TestJvmSpec(val project: Project) {
companion object {
const val TEST_JVM = "testJvm"

// TODO(JDK-28-EA): remove after GA (tip will move to 28)
internal fun resolveTipJavaVersion(javaVersions: List<Int>): String {
val tipJavaVersions = javaVersions.filterNot { it == 28 }
if (tipJavaVersions.isEmpty()) {
throw GradleException("No Java installations found for tip after excluding Java 28.")
}

return tipJavaVersions.max().toString()
}
}

/**
Expand All @@ -59,7 +69,7 @@ class TestJvmSpec(val project: Project) {
throw GradleException("No Java installations found via toolchains or JAVA_X_HOME environment variables.")
}

javaVersions.max().toString()
resolveTipJavaVersion(javaVersions) // TODO(JDK-28-EA): revert back to "javaVersions.max().toString()" after GA
Comment thread
bric3 marked this conversation as resolved.
Resolved
}

else -> testJvm
Expand Down
Loading