List<PsiElement> (String @NotNull [] testNames, @NotNull Project project) { final List<PsiElement> elements = new ArrayList<>(); PsiManager psiManager = PsiManager.getInstance(project); for (String testName : testNames) { int index = testName.indexOf(","); if (index <= 0) return elements; collectTestsByName(elements, testName.substring(index + 1), testName.substring(0, index), psiManager); } return elements; }