Running spring-boot-gradle-plugin tests with Eclipse fails out of the box because the spring-boot-loader.jar resource is missing. If you update spring-boot-loader-tools to include build/generated-resources/main as a source folder then the tests pass.

Comment From: wilkinsona

This has been bugging me too but I'm not totally sure what's going on.

If you update spring-boot-loader-tools to include build/generated-resources/main as a source folder

That's what this bit of the build.gradle for loader tools is already supposed to do:

sourceSets {
    main {
        output.dir(generatedResources, builtBy: [layerToolsJar, reproducibleLoaderJar])
    }
}

I've tried configuring it as an additional source dir rather than an output dir but it doesn't appear to work in Eclipse. On the command line it results in the layer tools and loader jars being packaged in the source jar which we don't want either.