IDEA-115838 FQN inserted for annotated code instead of using imports

This commit is contained in:
anna
2013-11-05 12:56:04 +01:00
parent ae7e30edee
commit 4af50cb817
2 changed files with 17 additions and 0 deletions
@@ -345,6 +345,7 @@ public class PsiImplUtil {
if (annotationType instanceof PsiClass) {
return findApplicableTarget((PsiClass)annotationType, types);
}
if (annotationType == null) return null;
}
}
@@ -166,6 +166,22 @@ class Test {
@TA
Collection<caret> c;
}
'''
}
public void testUnresolvedAnnotatedQualifiedImport() {
myFixture.configureByText 'a.java', '''
class Test {
@Nullable Collection<caret> c;
}
'''
importClass();
myFixture.checkResult '''import java.util.Collection;
class Test {
@Nullable
Collection<caret> c;
}
'''
}