void (@NotNull PsiMethod method) { super.visitMethod(method); final String name = method.getName(); if (!name.startsWith("test")) return; if (!TestUtils.isRunnable(method)) return; final PsiClass containingClass = method.getContainingClass(); if (containingClass == null) return; final TestFramework testFramework = TestFrameworks.detectFramework(containingClass); if (testFramework != null) { if (testFramework.isTestMethod(method, false)) { @NonNls final String testFrameworkName = testFramework.getName(); if (testFrameworkName.equals("JUnit4") || testFrameworkName.equals("JUnit5")) return; } if (AnnotationUtil.isAnnotated(method, "org.junit.Ignore", 0) || testFramework.findSetUpMethod(containingClass) == method || testFramework.findTearDownMethod(containingClass) == method) { return; } } if (TestUtils.isJUnitTestClass(containingClass)) return; if (!containsJUnit4Annotation(containingClass)) return; registerMethodError(method, method); }