Closed NotMyFault closed 1 year ago
I had something like this originally, but it missed some important edge cases. Now this plugin uses Gradle's toolchains to test against 8 and 11 here: https://github.com/jenkinsci/gradle-jpi-plugin/blob/22c6c985790407abf6e3c077cfa0ba55bc8f7e6a/build.gradle.kts#L130
I think the toolchains approach is more representative because we do compile and release with 8, but users can run with 11.
I think the toolchains approach is more representative because we do compile and release with 8, but users can run with 11.
I see, I'd like to see Java 11 added to the Jenkinsfile test cases too, given Java 11 is the Jenkins JDK baseline.
@NotMyFault All integration tests (that run Gradle via GradleTestKit) are being run against Java 11 on Jenkins as of https://github.com/jenkinsci/gradle-jpi-plugin/commit/4810e247f3a31d3c5cc113eab66a9e727a8e7f76. This can be seen here.
I see, I'd like to see Java 11 added to the Jenkinsfile test cases too, given Java 11 is the Jenkins JDK baseline.
We can do this, but it seems to make more sense for Jenkins plugins than this Gradle plugin. To that end, perhaps we shouldn't be calling buildPluginWithGradle
at all since we're not producing something to run in Jenkins here. Could you help me better understand the value of compiling against Java 11?
I don't believe Gradle has announced dropping Java 8 for any future release yet. Even if they do, the goal is to retain backwards compatiblity to Gradle 6.3 as long as possible, so it would likely be years after Gradle abandoned 8 that the jpi plugin would abandon 8.
Let's test it on Java 11 too.