throw more appropriate exceptions
added javadoc
don't run this integration test on jdk5 because its test build uses groovy 2.3