add tests for sorting criteria parsing