void () { int caretCount = 1000; int charactersToType = 100; String initialText = "<root>\n" + StringUtil.repeat(" <node><caret></node>\n", caretCount) + "</root>"; init(initialText, StdFileTypes.XML); PlatformTestUtil.startPerformanceTest("Typing in XML with large number of carets", 100_000, () -> { for (int i = 0; i < charactersToType; i++) { type('a'); } }).attempts(1).assertTiming(); checkResultByText("<root>\n" + StringUtil.repeat(" <node>" + StringUtil.repeat("a", charactersToType) + "<caret></node>\n", caretCount) + "</root>"); }