activated optimizer rule remove-sort-rand

fixed tests, updated documentation