two small dependencies fixes, one small test fix

This pull request contains three small changes that have caused me grief.

The way groovy-all was included, groovy code would be compiled against 2.3.1, but maven dependencies would include version 2.2.2. This caused my maven project to throw "ClassNotFoundException: org.codehaus.groovy.runtime.typehandling.ShortTypeHandling" because ShortTypeHandling is introduced in groovy 2.3. This is simply fixed by depending on 2.3.1.

The "latest.release" identifier is an ivy-specific syntax. I've changed it to "[0.4,)" which is compatible with both maven and ivy.

The testSort() test wasn't running properly. Mockito was preventing invocation of compareTo(), so I fixed that.