Some of our services have caches injected using Wirebox.
When trying to run the test harness, this errors with the message "The DSL Definition ... did not produce any resulting dependency"
The DSL Definition {JAVACAST={null},NAME={cache},ARGNAME={},DSL={cachebox:clientDB},VALUE={null},REQUIRED={true},SCOPE={variables},REF={null}} did not produce any resulting dependency
I can't find any examples of how to mock a cache - I tried adding the following to beforeAll in the base testcase:
Variables.Cachebox = getController().getCacheBox();
if ( NOT ArrayFind(Cachebox.getCacheNames(),'clientDB') )
{
var cache = new coldbox.system.cache.providers.MockProvider();
cache.setName('clientDB');
Cachebox.addCache(cache);
}
That doesn't do anything - same error.
How do I fix it?