mirror of
https://gitflic.ru/project/openide/openide.git
synced 2026-09-27 10:03:11 +07:00
expected type for expression inside annotation arg can't be array type (IDEA-150564)
This commit is contained in:
+34
@@ -25,6 +25,40 @@ class Test {
|
||||
'''
|
||||
assert !myFixture.lookup
|
||||
}
|
||||
|
||||
public void "test inside annotation argument with braces"() {
|
||||
TemplateManagerImpl.setTemplateTesting(project, testRootDisposable)
|
||||
myFixture.configureByText "a.java", '''
|
||||
interface A {}
|
||||
@SuppressWarnings({A.CON<caret>ST})
|
||||
class Test {}
|
||||
'''
|
||||
myFixture.launchAction(myFixture.findSingleIntention("Create constant field"))
|
||||
myFixture.checkResult '''
|
||||
interface A {
|
||||
<selection>String</selection> CONST = ;
|
||||
}
|
||||
@SuppressWarnings({A.CONST})
|
||||
class Test {}
|
||||
'''
|
||||
}
|
||||
|
||||
public void "test inside annotation argument no braces"() {
|
||||
TemplateManagerImpl.setTemplateTesting(project, testRootDisposable)
|
||||
myFixture.configureByText "a.java", '''
|
||||
interface A {}
|
||||
@SuppressWarnings(A.CON<caret>ST)
|
||||
class Test {}
|
||||
'''
|
||||
myFixture.launchAction(myFixture.findSingleIntention("Create constant field"))
|
||||
myFixture.checkResult '''
|
||||
interface A {
|
||||
<selection>String</selection> CONST = ;
|
||||
}
|
||||
@SuppressWarnings(A.CONST)
|
||||
class Test {}
|
||||
'''
|
||||
}
|
||||
|
||||
public void "test insert presentable name when showing type lookup"() {
|
||||
TemplateManagerImpl.setTemplateTesting(project, testRootDisposable)
|
||||
|
||||
Reference in New Issue
Block a user