I am using the GORM method findAll("query", [params], [pagination]), as per documentation : http://grails.org/doc/latest/ref/Domain%20Classes/findAll.html
It works fine at runtime, but it is not available during integration tests. It seems that only the findAll('query', [params]) and findAll('query') methods are available.
MORE DETAILS:
Query:
MyDomain.findAll("From MyDomain as domain Where domain.something = :something", [something:aThing], [max:10])
Test Setup:
I execute this method through an integration test (under test/integration, and my test class extends GroovyTestCase)
Environment: I am using grails 1.3.7, mac osx
StackTrace:
I get the following error: No signature of method: a.b.c.d.e.MyDomain.findAll() is applicable for argument types: (java.lang.String, java.util.LinkedHashMap, java.util.LinkedHashMap) Possible solutions: findAll(), findAll(java.lang.Object), findAll(java.lang.Object, java.util.Map), findAll(groovy.lang.Closure).
To reproduce it :
class MyTestClass extends GroovyTestCase{
void testFindAllFailsWithThreeParameters(){
Domain.findAll('From Domain as domain where domain.property = :value', [value:value],[max:10])
}
}
Thanks in advance for your help,
Vincent