Skip to content

Commit

Permalink
Fix docker packaging tests (#65199) (#65218)
Browse files Browse the repository at this point in the history
  • Loading branch information
breskeby authored Nov 18, 2020
1 parent f4af82c commit f914143
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 4 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -319,8 +319,12 @@ void finalizeValues() {
bundledJdk.finalizeValue();
}

public Configuration getArchive() {
maybeFreeze();
return configuration;
public TaskDependency getArchiveDependencies() {
if (skippingDockerDistributionBuild()) {
return task -> Collections.emptySet();
} else {
maybeFreeze();
return configuration.getBuildDependencies();
}
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -114,7 +114,7 @@ public void apply(Project project) {
String taskname = destructiveDistroTestTaskName(distribution);
TaskProvider<?> depsTask = project.getTasks().register(taskname + "#deps");
// explicitly depend on the archive not on the implicit extracted distribution
depsTask.configure(t -> t.dependsOn(distribution.getArchive(), examplePlugin, quotaAwareFsPlugin));
depsTask.configure(t -> t.dependsOn(distribution.getArchiveDependencies(), examplePlugin, quotaAwareFsPlugin));
depsTasks.put(taskname, depsTask);
TaskProvider<Test> destructiveTask = configureTestTask(project, taskname, distribution, t -> {
t.onlyIf(t2 -> distribution.isDocker() == false || dockerSupport.get().getDockerAvailability().isAvailable);
Expand Down

0 comments on commit f914143

Please sign in to comment.