Sort the right thing when running the tests

This reverts commit 6495de3c4584754644a9b7f565ec2d7b893fbbf9, because it was
sorting the wrong list.