void (String name, String inspectionName, String testDataSubPath, String expectedDescriptionFileName) { myFixture.configureByFile(testDataSubPath + name + ".xml"); myFixture.copyFileToProject(testDataSubPath + inspectionName + ".java"); myFixture.copyDirectoryToProject(testDataSubPath + "inspectionDescriptions", "inspectionDescriptions"); JavaPsiFacadeEx javaFacade = myFixture.getJavaFacade(); PsiClass inspectionClass = javaFacade.findClass(inspectionName); assertNotNull(inspectionName, inspectionClass); RenameProcessor processor = new RenameProcessor(getProject(), inspectionClass, "New" + inspectionName, true, true); for (AutomaticRenamerFactory factory : AutomaticRenamerFactory.EP_NAME.getExtensionList()) { processor.addRenamerFactory(factory); } processor.run(); PsiDocumentManager.getInstance(getProject()).commitAllDocuments(); FileDocumentManager.getInstance().saveAllDocuments(); myFixture.checkResultByFile(testDataSubPath + name + ".xml", testDataSubPath + name + "_after.xml", false); VirtualFile descriptionFile = myFixture.findFileInTempDir("inspectionDescriptions/" + expectedDescriptionFileName); assertNotNull(expectedDescriptionFileName, descriptionFile); }