Adding test for sort_array.