Skip to content

atschabu/gradle-sandbox

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

7 Commits
 
 
 
 
 
 
 
 

Repository files navigation

Gradle Sandbox

while moving a legacy build to Gradle I came upon several issues. Foremost of course due to my lack of knowledge about Gradle, but some are caused by Gradle itself.

The idea is to collect all code snippets which troubled me over time in a single place (right now they are distributed over several projects, folders and machines ...)

Furthermore I will try to use this space for all future experiments.

Testing custom Gradle plugins

While ProjectBuilder is a nice tool to create quickly (in terms of execution) a fake project which you can apply plugins to, it does not cover the actual execution of the build. As long as the plugin only uses build-in tasks this might be enough, as you can test if your configuration contains all your fake files and properties. Unfortunately for custom tasks this is no good.

Gradle integration tests

Using org.gradle:gradle-tooling-api it is possible to easily launch a Gradle build within a well known space, and test the actual execution of all tasks defined in a plugin. The main challenge is to create the fake environment.

While it is easy to create any environment, I will need to be able to replicate the actual development environment (including all its legacy flaws) as close as possible, to make sure my custom tasks only fail when they are supposed to fail (incorrect usage, configuration) and let the user know why they fail, and how it can be fixed.

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages