Monday, December 1, 2008

Any Code Analysis Tools for Groovy & Grails?

I had an interesting comment from one of the readers at Javalobby. To quote him:

Hello Meera,

I was just wondering if we have a code analysis tool in the market that integrates and works well with Grails & Groovy? Your response is very much appreciated and valued.

Many Thanks,


I have used code analysis tools for both Java & .NET, but none for Groovy until now. I am pretty sure FindBugs which analyzes the byte code might work for Groovy and Grails. All other tools inspect the source code, so we might not be able to use any of them.

Have you used any such tool with Groovy & Grails? Any ideas? If so, please share your thoughts.


  1. There is a Code Coverage plugin which evaluates code coverage of unit tests, not exactly what you're looking for, but close:

  2. After reading the comment at Javalobby, I was looking for tools such as PMD, CPD, CheckStyle, JavaNCSS, Cobertura and so on.. to see if they work with Groovy and Grails.

    Thanks for sharing this, Mike.

  3. Cobertura works well with Grails for code coverage. Although FindBugs can be run on the generated classes from groovy/grails but I was not sure whether we can map it back to source code.

  4. FYI: Here is a very basic checkstyle like tool for Groovy.

  5. thanks for sharing this site. there are various kinds of ebooks available from here

  6. Code inspection tools is very helpful and powerful tool.