Refactored the Java templates into task classes and added tests.
Refactored the groovy tasks and created tests.
Refactored the gradle plugin tasks and added tests.