Update Distinct() and add tests