Polish test sourceSet dependencies

Remove all direct sourceSets.test.output dependencies and instead rely
on the 'test-source-set-dependencies' plugin.

This commit also updates the api JavaDoc task to ensure that
dependencies are not resolved too early.
This commit is contained in:
Phillip Webb 2013-01-03 22:47:11 -08:00 committed by Chris Beams
parent d52f883453
commit 16a3a8bda8
1 changed files with 13 additions and 13 deletions

View File

@ -603,7 +603,6 @@ project("spring-webmvc") {
testCompile("commons-io:commons-io:1.3")
testCompile("org.hibernate:hibernate-validator:4.3.0.Final")
testCompile("org.apache.httpcomponents:httpclient:4.2")
testCompile(project(":spring-web").sourceSets.test.output)
}
// pick up DispatcherServlet.properties in src/main
@ -615,6 +614,7 @@ project("spring-webmvc-tiles3") {
merge.into = project(":spring-webmvc")
dependencies {
compile(project(":spring-context"))
compile(project(":spring-web"))
provided("javax.el:el-api:1.0")
provided("javax.servlet:jstl:1.2")
provided("javax.servlet.jsp:jsp-api:2.1")
@ -633,7 +633,6 @@ project("spring-webmvc-tiles3") {
exclude group: "org.slf4j", module: "jcl-over-slf4j"
}
provided("javax.servlet:javax.servlet-api:3.0.1")
compile(project(":spring-web").sourceSets*.output) // mock request & response
testCompile("org.slf4j:slf4j-jcl:${slf4jVersion}")
}
}
@ -777,7 +776,6 @@ configure(rootProject) {
dependencies { // for integration tests
testCompile(project(":spring-core"))
testCompile(project(":spring-core").sourceSets.test.output)
testCompile(project(":spring-beans"))
testCompile(project(":spring-aop"))
testCompile(project(":spring-expression"))
@ -813,6 +811,10 @@ configure(rootProject) {
project.sourceSets.main.allJava
}
maxMemory = "1024m"
destinationDir = new File(buildDir, "api")
doFirst {
classpath = files(
// ensure servlet 3.x and Hibernate 4.x have precedence on the Javadoc
// classpath over their respective 2.5 and 3.x variants
@ -822,9 +824,7 @@ configure(rootProject) {
project(":spring-aspects").sourceSets.main.output
)
classpath += files(subprojects.collect { it.sourceSets.main.compileClasspath })
maxMemory = "1024m"
destinationDir = new File(buildDir, "api")
}
}
task docsZip(type: Zip) {