Thursday, January 27, 2011

Sample pom.xml For Groovy Project with Spock

Had to setup a new Groovy project using Maven today with Spock as its testing framework. Ran into a few glitch; thought to share it here with a sample pom.xml as a day-log.






4.0.0

sample-group
sample
General Purpose Groovy Project
jar
1.0-SNAPSHOT


0.4-groovy-1.7





org.codehaus.gmaven
gmaven-plugin
1.3



1.7


generateStubs
compile
generateTestStubs
testCompile






org.spockframework
spock-maven
${spock.version}



find-specs









org.codehaus.gmaven.runtime
gmaven-runtime-1.7
1.3



org.spockframework
spock-core
${spock.version}
test






Few things I ran into:

  1. Maven 3 currently does not work with the Spock plugin
  2. Spock plugin version 0.5-groovy-1.7 does not seem to pick up unit spec test correctly, so I had to fall back to 0.4 to make it work
  3. In order to mix both Java and Groovy code you need to enable the stub generate execution phase in GMaven plugin

Tuesday, January 04, 2011

JNDI Warrior v0.1 Released

It started as a simple demonstration application to showcase Griffon framework’s capability to deliver rich Swing based client application with unprecedented speed. However the demo itself turned out to be quite a handy little tool especially for Java EE developers, I personally had used it a couple of times to debug some odd JNDI lookup and classpath issues in the last a couple of weeks. So I have decided to officially host it on SourceForge.net as an open source project - JNDI Warrior.

Its a simple Swing based client utility application which allows you to connect to a given JNDI provider typically found with any Java EE application server. It has three JNDI templates built-in (Weblogic, JBoss AS, and Glassfish) to help you filling some of the blanks, but in theory it should work like any Java based JNDI client with any provider by manually entering your JNDI settings. You can download this little application from here.

You are always welcome to use project Trac to submit any bug report or feature request.

Happy new year! and enjoy :)

Here are a few screen shots: