Skip to content

Commit

Permalink
Lazily register generate-test-hpl task
Browse files Browse the repository at this point in the history
  • Loading branch information
sghill committed Nov 22, 2019
1 parent ef8b7de commit 7a565d3
Showing 1 changed file with 5 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -400,9 +400,11 @@ class JpiPlugin implements Plugin<Project> {
SourceSet testSourceSet = javaConvention.sourceSets.getByName(TEST_SOURCE_SET_NAME)

// generate test hpl manifest for the current plugin, to be used during unit test
GenerateTestHpl generateTestHpl = project.tasks.create('generate-test-hpl', GenerateTestHpl)
generateTestHpl.hplDir.set(project.layout.buildDirectory.dir('generated-resources/test'))
testSourceSet.output.dir(generateTestHpl.hplDir)
def outputDir = project.layout.buildDirectory.dir('generated-resources/test')
project.tasks.register('generate-test-hpl', GenerateTestHpl) {
it.hplDir.set(outputDir)
}
testSourceSet.output.dir(outputDir)
}

private static void resolvePluginDependencies(Project project) {
Expand Down

0 comments on commit 7a565d3

Please sign in to comment.