UT for sorting using declarations