Set dependencies = task.getTaskDependencies().getDependencies(task);
assertThat(dependencies, equalTo((Set) toSet(project.getTasks().getByName(WarPlugin.WAR_TASK_NAME))));
}
private void assertHasConfigurationAndMapping(DefaultProject project, String configurationName, String scope, int priority) {
Conf2ScopeMappingContainer scopeMappingContainer = project.getConvention().getPlugin(MavenPluginConvention.class).getConf2ScopeMappings();
ConfigurationContainer configurationContainer = project.getConfigurations();
Conf2ScopeMapping mapping = scopeMappingContainer.getMappings().get(configurationContainer.getByName(configurationName));
assertThat(mapping.getScope(), equalTo(scope));
assertThat(mapping.getPriority(), equalTo(priority));
}