Fixed search and sort test