Skip to content

Commit

Permalink
Fix generate-test-hpl task dependency for running tests
Browse files Browse the repository at this point in the history
This issue was introduced in commit 7a565d3,
when lazily registering the task.
  • Loading branch information
darxriggs committed Jan 1, 2020
1 parent 77f4977 commit c83c710
Showing 1 changed file with 5 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -422,10 +422,13 @@ class JpiPlugin implements Plugin<Project> {

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

def generateTestHplTask = project.tasks.register('generate-test-hpl', GenerateTestHpl) {
it.hplDir.set(outputDir)
}
testSourceSet.output.dir(outputDir)

project.tasks.named(JavaPlugin.TEST_CLASSES_TASK_NAME).configure { it.dependsOn(generateTestHplTask) }
}

private static void resolvePluginDependencies(Project project) {
Expand Down

0 comments on commit c83c710

Please sign in to comment.