void () { String text = "<xml> \n" + StringUtil.repeatSymbol('\n', 1000) + "</xml>\nxxxxx<caret>"; configureByText(XmlFileType.INSTANCE, text); ProperTextRange visibleRange = makeEditorWindowVisible(new Point(0, 1000), myEditor); assertTrue(visibleRange.getStartOffset() > 0); HighlightInfo info = assertOneElement(highlightErrors()); assertEquals("Top level element is not completed", info.getDescription()); type("xxx"); info = assertOneElement(highlightErrors()); assertEquals("Top level element is not completed", info.getDescription()); }