Sorting added to optimize imports, enabled by default. All optimize imports tests were fixed.