use of com.intellij.codeInsight.generation.JavaOverrideMethodsHandler in project intellij-community by JetBrains.
the class OverrideImplement15Test method testInAnnotationType.
public void testInAnnotationType() {
String name = getTestName(false);
configureByFile(BASE_DIR + "before" + name + ".java");
int offset = getEditor().getCaretModel().getOffset();
PsiElement context = getFile().findElementAt(offset);
final PsiClass aClass = PsiTreeUtil.getParentOfType(context, PsiClass.class);
assertTrue(aClass != null && aClass.isAnnotationType());
final JavaOverrideMethodsHandler handler = new JavaOverrideMethodsHandler();
assertTrue(handler.isValidFor(getEditor(), getFile()));
assertFalse(handler.isAvailableForQuickList(getEditor(), getFile(), new MapDataContext()));
}
Aggregations