Index Sort: add test which should remove duplicate sort.