void (String text) { configureFromFileText("Foo." + getFileExtension(), text); EditorTestUtil.setEditorVisibleSize(getEditor(), 1000, 1000); // set visible area for highlighting List<TextRange> expectedTodoRanges = extractExpectedTodoRanges(getEditor().getDocument()); List<HighlightInfo> highlightInfos = doHighlighting(); List<TextRange> actualTodoRanges = getActualTodoRanges(highlightInfos); assertTodoRanges(expectedTodoRanges, actualTodoRanges); assertSameTodoCountInIndexAndHighlighting(); }