Complete mapping and sorting test