Merge branch '6.1.x'
This commit is contained in:
commit
94e2bef9a3
|
@ -77,6 +77,19 @@ eclipse.classpath.file.whenMerged {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// Due to an apparent bug in Gradle, even though we exclude the "main" classpath
|
||||||
|
// entries for sources generated by XJC in spring-oxm.gradle, the Gradle eclipse
|
||||||
|
// plugin still includes them in the generated .classpath file. So, we have to
|
||||||
|
// manually remove those lingering "main" entries.
|
||||||
|
if (project.name == "spring-oxm") {
|
||||||
|
eclipse.classpath.file.whenMerged { classpath ->
|
||||||
|
classpath.entries.removeAll {
|
||||||
|
it.path =~ /build\/generated\/sources\/xjc\/.+/ &&
|
||||||
|
it.entryAttributes.get("gradle_scope") == "main"
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
// Include project specific settings
|
// Include project specific settings
|
||||||
task eclipseSettings(type: Copy) {
|
task eclipseSettings(type: Copy) {
|
||||||
from rootProject.files(
|
from rootProject.files(
|
||||||
|
|
|
@ -20,7 +20,6 @@ dependencies {
|
||||||
testImplementation("org.codehaus.jettison:jettison") {
|
testImplementation("org.codehaus.jettison:jettison") {
|
||||||
exclude group: "stax", module: "stax-api"
|
exclude group: "stax", module: "stax-api"
|
||||||
}
|
}
|
||||||
//testImplementation(files(genJaxb.classesDir).builtBy(genJaxb))
|
|
||||||
testImplementation("org.xmlunit:xmlunit-assertj")
|
testImplementation("org.xmlunit:xmlunit-assertj")
|
||||||
testImplementation("org.xmlunit:xmlunit-matchers")
|
testImplementation("org.xmlunit:xmlunit-matchers")
|
||||||
testRuntimeOnly("com.sun.xml.bind:jaxb-core")
|
testRuntimeOnly("com.sun.xml.bind:jaxb-core")
|
||||||
|
@ -28,14 +27,13 @@ dependencies {
|
||||||
}
|
}
|
||||||
|
|
||||||
tasks.named("xjc").configure { xjc ->
|
tasks.named("xjc").configure { xjc ->
|
||||||
// XJC plugin only works against main sources
|
// XJC plugin only works against main sources, so we have to "move" them to test sources.
|
||||||
def javaSrcDirs = sourceSets.main.java.srcDirs
|
sourceSets.main.java.exclude {
|
||||||
javaSrcDirs.remove(file(xjc.outputJavaDir))
|
it.file.absolutePath.startsWith(outputJavaDir.get().asFile.absolutePath)
|
||||||
sourceSets.main.java.srcDirs = javaSrcDirs
|
}
|
||||||
def resourcesSrcDirs = sourceSets.main.resources.srcDirs
|
sourceSets.main.resources.exclude {
|
||||||
resourcesSrcDirs.remove(file(xjc.outputResourcesDir))
|
it.file.absolutePath.startsWith(outputResourcesDir.get().asFile.absolutePath)
|
||||||
sourceSets.main.resources.srcDirs = resourcesSrcDirs
|
}
|
||||||
|
|
||||||
sourceSets.test.java.srcDir(xjc.outputJavaDir)
|
sourceSets.test.java.srcDir(xjc.outputJavaDir)
|
||||||
sourceSets.test.resources.srcDir(xjc.outputResourcesDir)
|
sourceSets.test.resources.srcDir(xjc.outputResourcesDir)
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue