sort returned list in test