Merge branch '1.1.x'

This commit is contained in:
Andy Wilkinson
2015-01-21 15:09:27 +00:00
4 changed files with 50 additions and 5 deletions

View File

@@ -63,4 +63,17 @@ public class MultiProjectRepackagingTests {
assertThat(jarFile.getEntry("lib/foo.jar"), notNullValue());
jarFile.close();
}
@Test
public void repackageWithRuntimeProjectDependency() throws Exception {
ProjectConnection project = new ProjectCreator()
.createProject("multi-project-runtime-project-dependency");
project.newBuild().forTasks("clean", "build")
.withArguments("-PbootVersion=" + BOOT_VERSION).run();
File buildLibs = new File(
"target/multi-project-runtime-project-dependency/projectA/build/libs");
JarFile jarFile = new JarFile(new File(buildLibs, "projectA.jar"));
assertThat(jarFile.getEntry("lib/projectB.jar"), notNullValue());
jarFile.close();
}
}

View File

@@ -0,0 +1,22 @@
buildscript {
repositories {
mavenLocal()
}
dependencies {
classpath "org.springframework.boot:spring-boot-gradle-plugin:${project.bootVersion}"
}
}
project(':projectA') {
apply plugin: 'spring-boot'
dependencies {
runtime project(':projectB')
}
bootRepackage {
mainClass 'com.foo.Bar'
}
}
project(':projectB') {
apply plugin: 'java'
}

View File

@@ -0,0 +1 @@
include 'projectA', 'projectB'