Details
Description
GrailsUnitTestCase provides a mockConfig(String config) method
This works for code that access the config by calling ConfigurationHolder.config, but not code that calls grailsApplication.config.
If mockConfig could return the ConfigObject it creates, then it would be easier to add the mocked config to grailsApplication:
def config = mockConfig('foo.bar = 200')
controller.metaClass.grailsApplication = [config: config]
Pull request: https://github.com/grails/grails-core/pull/34