$ gradle -v
------------------------------------------------------------
Gradle 2.0-rc-1
------------------------------------------------------------
Build time:
2014-06-06 07:02:41 UTC
Build number: none
Revision:
b6ead6fa452dfdadec484059191eb641d817226c
Groovy:
2.3.2
Ant:
Apache Ant(TM) version 1.9.3 compiled on December 23 2013
JVM:
1.7.0_55 (Oracle Corporation 24.51-b03)
OS:
Linux 3.14.5-1-ARCH amd64
$ find -type f | sort
./build.gradle
./src/test/java/SimpleTest.java
$ gradle pmdTest
:pmdTest FAILED
FAILURE: Build failed with an exception.
* What went wrong:
Execution failed for task ':pmdTest'.
> Can't find resource null.
Make sure the resource is a valid file or URL and is on the CLASSPATH. Here's the current classpath: /home/agt/lib/gradle-2.0-rc-1/lib/gradle-launcher-2.0-rc-1.jar
* Try:
Run with --stacktrace option to get the stack trace. Run with --info or --debug option to get more log output.
BUILD FAILED
Total time: 3.088 secs
Stack trace: https://gist.github.com/agt-the-walker/46e7d4e567a91dd0c8fa#file-gradle-pmdtest-stacktrace
ābuild.gradleā contains:
apply plugin: 'java'
apply plugin: 'pmd'
repositories { mavenCentral() }
dependencies { testCompile group: 'junit', name: 'junit', version: '4.+' }
pmd { ruleSets = ["basic", "braces"] }
āsrc/test/java/SimpleTest.javaā contains:
import static org.junit.Assert.assertTrue;
import org.junit.Test;
import java.util.ArrayList;
import java.util.Collection;
public class SimpleTest {
@Test
public void testEmptyCollection() {
Collection collection = new ArrayList();
assertTrue(collection.isEmpty());
}
}
Note that āgradle pmdTestā succeeds if I remove ābracesā from āruleSetsā.
More details upon request. Thanks for your time.