On 27/02/10 7:31 AM, Tomek Kaczanowski wrote:
You are probably well aware of that, but TestNG is not working at all
with the latest snapshot available
Gradle 0.9-20100224120231+0300
The TestNG samples are working fine, so it's not completely broken.
I have a test project with failing tests and it passes (and I can't
see trace of tests execution anywhere).
The output of gradle -i or gradle -d should list the tests that are being
executed. And build/reports/test should have a bunch of results in it. Are
you seeing any of this stuff?
It works as long as you don't mess with listeners. This will work:
test {
useTestNG()
}
but this does not:
apply id: 'java'
repositories {
mavenCentral()
mavenRepo urls: 'http://download.java.net/maven/2/'
}
dependencies {
testCompile 'org.uncommons:reportng:1.0'
testCompile 'org.testng:testng:5.10:jd...@jar'
}
test {
useTestNG()
options.listeners<<
'org.uncommons.reportng.HTMLReporter,org.uncommons.reportng.JUnitXMLReporter'
You need to split these class names into separate strings. The test
execute treats each entry in the options.listeners list as a class name
to load.
options.listeners << 'org.uncommons.reportng.HTMLReporter'
options.listeners << 'org.uncommons.reportng.JUnitXMLReporter'
The fact that there was no error message telling you this, and that the
build didn't break, are bugs. I've checked in a fix so that the build
will break now, rather than pretend that it executed the tests and they
all passed. The error message is still completely useless, but I will
fix that some time soon.
--
Adam Murdoch
Gradle Developer
http://www.gradle.org
---------------------------------------------------------------------
To unsubscribe from this list, please visit:
http://xircles.codehaus.org/manage_email