Fix EZP-22786: Legacy SearchHandlerTest::testStatusFilter fails on php 5.5.11

The PR resolves issue https://jira.ez.no/browse/EZP-22786

Tested query is limited to 10 but has larger total count and therefore order returned for the DB can be significant.

This adds sort clause to the query and additionally asserts total count.