we are preparing for Grails 2.4 upgrade. One of the issues we face is that most of the command object unit tests fails because of injected properties, like services, are required to be not null during validation.
Is there any suggested way how to test this? Should we mock all properties although some are not needed for test? or is there a way to do this differently?
After my question is answered by Jeff, I share links with more information about new functionalities: doWithSpring and doWithConfig are shortly described in What's new in 2.4: http://grails.org/doc/latest/guide/introduction.html#whatsNew24 in Unit Testing improvements section There is also a JIRA issue with example: https://jira.grails.org/browse/GRAILS-11003