added tests for xSortBy