void () { final int typoCount = 5000; @SuppressWarnings("SpellCheckingInspection") String text = StringUtil.repeat("aaaaaaaaa ", typoCount); // about 0.5M long start = System.currentTimeMillis(); VirtualFile file = myFixture.addFileToProject("foo.txt", text).getVirtualFile(); LOG.debug("creation took " + (System.currentTimeMillis() - start) + " ms"); start = System.currentTimeMillis(); myFixture.configureFromExistingVirtualFile(file); LOG.debug("configure took " + (System.currentTimeMillis() - start) + " ms"); start = System.currentTimeMillis(); runLocalInspections(); LOG.debug("warm-up took " + (System.currentTimeMillis() - start) + " ms"); DaemonCodeAnalyzer.getInstance(getProject()).restart(); int[] toIgnore = ignoreEverythingExceptInspections(); PlatformTestUtil.startPerformanceTest("many typos highlighting", 12_000, () -> { assertSize(typoCount, CodeInsightTestFixtureImpl.instantiateAndRun(myFixture.getFile(), myFixture.getEditor(), toIgnore, false)); }).assertTiming(); }