Moved setting of 'provided' scope mapping on pom out of whenConfigured() so that the mapping is in place when the pom dependencies are assembled. Added 'skipTests' option.

This commit is contained in:
Luke Taylor 2010-03-07 23:53:33 +00:00
parent f3264ba9ab
commit 6fcaba2c46
2 changed files with 6 additions and 1 deletions

View File

@ -38,6 +38,9 @@ dependencies {
}
test {
onlyIf {
!project.hasProperty('skipTests')
}
jvmArgs = ['-ea', '-Xms128m', '-Xmx500m', '-XX:MaxPermSize=128m']
}

View File

@ -54,9 +54,11 @@ installer = install.repositories.mavenInstaller
def optionalDeps = ['commons-logging', 'ehcache', 'log4j', 'apacheds-core', 'jsp-api', 'jsr250-api', 'ldapsdk']
[installer, deployer]*.pom*.whenConfigured { pom ->
[installer, deployer]*.pom.collect { pom ->
pom.scopeMappings.addMapping(10, configurations.provided, 'provided')
}
[installer, deployer]*.pom*.whenConfigured { pom ->
pom.dependencies.findAll { dep ->
optionalDeps.contains(dep.artifactId) ||
dep.groupId.startsWith('org.apache.directory') ||