void (String text, Consumer<PsiBuilder> parser) { String name = getTestName(false); myFile = createPsiFile(name, text, parser); myFile.putUserData(PsiUtil.FILE_LANGUAGE_LEVEL_KEY, myLanguageLevel); try { checkResult(name, myFile); } catch (IOException e) { throw new RuntimeException(e); } }