Adam Murdoch-3 wrote > On 11/07/10 12:41 AM, David Rosell wrote: >> Last, I'd like to suggest adding something like this scalatest task to >> the Scala Plugin section in the documentation, it is nice to have >> working examples how to extend gradle's capabilities in context, and >> now that the "run a program" is fixed so that you doesn't need ant for >> that, this could be another... > > I think I'd rather add ScalaTest support to the test task. I've added an > issue for this: http://jira.codehaus.org/browse/GRADLE-1032
Noticed this is still open, the ant task works pretty well though. test << { ant.taskdef( name: 'scalatest', classname: 'org.scalatest.tools.ScalaTestAntTask', classpath: classpath.asPath) ant.scalatest( runpath: testClassesDir, haltonfailure: 'true', fork: 'false') { reporter(type: 'stderr') } } If you use 'stdout', you need to run gradle with --info to see the details. If you want to replace the test task, then use the classpath and runpath as shown below: task test(overwrite: true, dependsOn: compileTestScala) << { ant.taskdef( name: 'scalatest', classname: 'org.scalatest.tools.ScalaTestAntTask', classpath: configurations.testRuntime.asPath+':'+compileScala.destinationDir ) ant.scalatest( runpath: sourceSets.test.output.classesDir, haltonfailure: 'true', fork: 'false' ) { reporter(type: 'stderr') } } Mike Hancock -- View this message in context: http://gradle.1045684.n5.nabble.com/Running-ScalaTest-suites-tp1435916p5710630.html Sent from the gradle-user mailing list archive at Nabble.com. --------------------------------------------------------------------- To unsubscribe from this list, please visit: http://xircles.codehaus.org/manage_email