summaryrefslogtreecommitdiff
path: root/java/java-tests/testSrc/com/intellij/codeInsight/completion/NormalCompletionTest.groovy
diff options
context:
space:
mode:
Diffstat (limited to 'java/java-tests/testSrc/com/intellij/codeInsight/completion/NormalCompletionTest.groovy')
-rw-r--r--java/java-tests/testSrc/com/intellij/codeInsight/completion/NormalCompletionTest.groovy17
1 files changed, 15 insertions, 2 deletions
diff --git a/java/java-tests/testSrc/com/intellij/codeInsight/completion/NormalCompletionTest.groovy b/java/java-tests/testSrc/com/intellij/codeInsight/completion/NormalCompletionTest.groovy
index ba38fd1a45ad..79a94aaa8148 100644
--- a/java/java-tests/testSrc/com/intellij/codeInsight/completion/NormalCompletionTest.groovy
+++ b/java/java-tests/testSrc/com/intellij/codeInsight/completion/NormalCompletionTest.groovy
@@ -792,7 +792,7 @@ public class ListUtils {
public void testDoubleFalse() throws Throwable {
configureByFile(getTestName(false) + ".java");
- assertFirstStringItems("false", "fefefef", "float", "finalize");
+ assertFirstStringItems("fefefef", "false", "float", "finalize");
}
public void testSameNamedVariableInNestedClasses() throws Throwable {
@@ -938,6 +938,13 @@ public class ListUtils {
public void testQualifyInnerMembers() throws Throwable { doTest('\n') }
+ public void testDeepInner() throws Throwable {
+ configure()
+ assert myFixture.lookupElementStrings == ['ClassInner1', 'ClassInner1.ClassInner2']
+ selectItem(lookup.items[1])
+ checkResult()
+ }
+
public void testSuggestExpectedTypeMembers() throws Throwable { doTest('\n') }
public void testSuggestExpectedTypeMembersInCall() throws Throwable { doTest('\n') }
public void testSuggestExpectedTypeMembersInAnno() throws Throwable { doTest('\n') }
@@ -1209,6 +1216,12 @@ class XInternalError {}
public void testConstantInAnno() { doTest() }
+ public void testCharsetName() {
+ myFixture.addClass("package java.nio.charset; public class Charset { public static Charset forName(String s) {} }")
+ configureByTestName()
+ assert myFixture.lookupElementStrings.contains('UTF-8')
+ }
+
public void testInnerClassInExtendsGenerics() {
def text = "package bar; class Foo extends List<Inne<caret>> { public static class Inner {} }"
myFixture.configureFromExistingVirtualFile(myFixture.addClass(text).containingFile.virtualFile)
@@ -1240,7 +1253,7 @@ class XInternalError {}
configure()
def items = myFixture.lookupElements.findAll { it.lookupString == 'String' }
assert items.size() == 1
- assert LookupElementPresentation.renderElement(items[0]).tailText?.contains('java.lang')
+ assert LookupElementPresentation.renderElement(items[0]).tailText == ' (java.lang)'
}
public void testSameSignature() {