Quantcast

The sort parameter doesn't work in unit tests when applied to a dynamic finder

classic Classic list List threaded Threaded
1 message Options
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate
star

The sort parameter doesn't work in unit tests when applied to a dynamic finder

Dean Del Ponte-2
Here's my code:

Domain.findAllByName("my name", [sort: "displayOrder", order: "asc"] 

I would expect the results of this query to be sorted by the field "displayOrder".

This works fine during run-app.

This does not work in unit tests.

Is this expected behavior for unit tests or a bug?

Anyone aware of a work around?

Thanks,

Dean Del Ponte
Loading...