-
Notifications
You must be signed in to change notification settings - Fork 7
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Fix Gradle 8.1 Compatibility #26
Fix Gradle 8.1 Compatibility #26
Conversation
Make it run twice, to ensure second run will actually use cached values
id 'jacoco' | ||
id 'java-gradle-plugin' | ||
id 'pl.droidsonroids.jacoco.testkit' version '1.0.8' | ||
// id 'pl.droidsonroids.jacoco.testkit' version '1.0.8' |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Can be uncommented after the release
@@ -16,7 +16,7 @@ class JaCoCoTestKitPluginFunctionalTest { | |||
|
|||
@Before | |||
fun setUp() { | |||
temporaryFolder.newFile("gradle.properties").fillFromResource("testkit-gradle.properties") | |||
temporaryFolder.newFile("gradle.properties") |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
💡 I think I now know what this was, it's the "intergration" with jacoco! The file is not generated because I uncommented the plugin in build.gradle
it.outputFile = File(buildDir, "testkit/${taskProvider.name}/testkit-gradle.properties") | ||
it.destinationFile.set( |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I haven't understood what's the difference between destination and output file, since they point at the same location. I followed my intuition and the JacocoTaskExtension's destinationFile is now used only as org.gradle.jvmargs
property value
After upgrading to Gradle 8.1 the build fails with
This is an attempt to fix it. I'm not 100% sure it will work in all supported cases, I haven't fully understood the test setup, so you may take these changes with a grain of salt (especially the ones around publishing).
I tested locally and they seem to work 👀