Testing plugin using composite build

I am writing a simple plugin that I can make public and I would like to try all the “new” stuff, such as the java-gradle-plugin, publish-plugin, testKit(), etc.

I got a first cut of the plugin and I would like to test it with existing project before publishing. I have read somewhere that I should be able to use composite builds for that, but when I list my plugin ID and the version in the plugins { ... } block I get an error:

Plugin [id: 'io.github.ddimtirov.codacy', version: '0.1.0-SNAPSHOT'] was not found in any of the following sources:

- Gradle Core Plugins (plugin is not in 'org.gradle' namespace)
- Gradle Central Plugin Repository (snapshot plugin versions are not supported)

When I add it to the buildscript classpath and apply it with the apply plugin: <id> syntax it works.

Am I doing something wrong, or is this a known issue? Is there any plan to integrate the plugin classpath discovery with composite builds?

@st_oehme any idea?

The plugins block doesn’t work with composites yet. We plan to fix that by the middle of this year.

1 Like


It would be a great feature. Any idea when it would be available ?



This is on our radar to address after the Gradle Summit, which is at the end of June. In the mean time, you can use the buildscript {} block as in this sample: https://github.com/gradle/gradle/tree/master/subprojects/docs/src/samples/compositeBuilds/plugin-dev

Thx for your answer. I saw this alternative. I’ll be patient :slight_smile: