void (@NotNull PsiFile file, ChangedLines... expected) { ChangedLines[] formatted = myMockCodeStyleManager.getFormattedLinesFor(file); Comparator<ChangedLines> cmp = Comparator.comparingInt(o -> o.from); Arrays.sort(expected, cmp); Arrays.sort(formatted, cmp); assertArrayEquals(getErrorMessage(expected, formatted), expected, formatted); }