hauner / gradle-plugins

Gradle Plugins
25 stars 8 forks source link

Support Gradle 8.x #8

Open lbenedetto opened 1 year ago

lbenedetto commented 1 year ago

After updating to Gradle 8.0.2:

Could not set unknown property 'classifier' for task ':jarTest'

Seems classifier was deprecated a while ago and finally removed

hauner commented 1 year ago

I don't think I will update the plugin. It is old and has just a few lines of of gradle configuration. Simply copy it to your build.gradle and adjust it.

Here is the code: https://github.com/hauner/gradle-plugins/blob/master/jartest/src/main/groovy/com/github/hauner/gradle/jartest/JarTestPlugin.groovy

DaGeRe commented 1 year ago

Thanks for this hint. While its easy to copy the lines in every Gradle configuration, its still a bit annoying to have all these lines in the configuration. I've adjusted the plugin and created a PR: https://github.com/hauner/gradle-plugins/pull/9 Could you look over it, and release it, if it works?

hauner commented 1 year ago

there was a bit more to do than in #9, but thanks for the starter :-) I created a new version 1.1.0.

It is now waiting for approval on plugins.gradle.org, should be available in a few days.

lbenedetto commented 1 year ago

Thanks for updating.

I ended up switching to a relatively new gradle feature called java-test-fixtures which is a cleaner solution for my project anyway. It allows sharing of specific classes between test modules.

https://docs.gradle.org/current/userguide/java_testing.html#sec:java_test_fixtures

People encountering this thread may want to consider if it makes sense for them as well.

hauner commented 1 year ago

Yes, found the built-in stuff as well and linked to it in the README. :-)