diff --git a/.gitignore b/.gitignore index 23c08a2b05819cc74de3194ce7a87290e6f4896f..71608becab11ff85dc71b08b56196fef9922f9c4 100644 --- a/.gitignore +++ b/.gitignore @@ -4,5 +4,6 @@ /.settings /.vagrant /bin +/bin-test /build /test-output diff --git a/build.gradle b/build.gradle index 8342a02fda3ffb6be3a3aeaf28dbd37b5afb8b65..418a6c46b3d1a4e4508a4f0614fdd3fda1995ea4 100644 --- a/build.gradle +++ b/build.gradle @@ -80,6 +80,7 @@ dependencies { compile group: 'com.fasterxml.jackson.core', name: 'jackson-core', version: '2.3.0' compile group: 'com.fasterxml.jackson.core', name: 'jackson-databind', version: '2.3.0' compile group: 'com.google.code.findbugs', name: 'annotations', version: '2.0.3' + compile group: 'com.tngtech.java', name: 'config-builder', version: '1.1' compile(group: 'org.postgis', name: 'postgis-jdbc', version:'1.3+') { exclude(module: 'postgis-stubs') } @@ -163,12 +164,19 @@ eclipse { eclipse.classpath.file { // See: http://stackoverflow.com/questions/12836089/why-is-eclipse-not-attaching-3rd-party-libs-source-files-to-a-wtp-faceted-gradle - // Classpath entry for Eclipse which changes the order of classpathentries; otherwise no sources for 3rd party jars are shown + // Chnanges eclipse classpath entries; otherwise no sources for 3rd party jars are shown withXml { xml -> def node = xml.asNode() node.remove( node.find { it.@path == 'org.eclipse.jst.j2ee.internal.web.container' } ) node.appendNode( 'classpathentry', [ kind: 'con', path: 'org.eclipse.jst.j2ee.internal.web.container', exported: 'true']) } + + // See: http://forums.gradle.org/gradle/topics/eclipse_wtp_deploys_testcode_to_server_example_provided + // Sets output folders for compiled classes and resources... otherwise test classes/resources would be deployed to wtp server + whenMerged { cp -> + cp.entries.findAll { it.path.startsWith("src/main/") }*.output = "bin" + cp.entries.findAll { it.path.startsWith("src/test/") }*.output = "bin-test" + } } findbugs {