Fix: IDEA-70400 'Go To Test' for Grails 1.4 tests using @TestFor

This commit is contained in:
Sergey Evdokimov
2011-06-02 02:10:57 +04:00
parent 69e549128e
commit 73e9ec3bef
3 changed files with 13 additions and 33 deletions
@@ -12,11 +12,16 @@ public abstract class JUnitRecognizer {
public static final ExtensionPointName<JUnitRecognizer> EP_NAME = ExtensionPointName.create("com.intellij.junitRecognizer");
public boolean isTestClass(@NotNull PsiClass aClass) {
public abstract boolean isTestAnnotated(@NotNull PsiMethod method);
public static boolean willBeAnnotatedAfterCompilation(@NotNull PsiMethod method) {
for (JUnitRecognizer jUnitRecognizer : EP_NAME.getExtensions()) {
if (jUnitRecognizer.isTestAnnotated(method)) {
return true;
}
}
return false;
}
public boolean isTestMethod(@NotNull PsiMethod method) {
return false;
}
}