mirror of
https://gitflic.ru/project/openide/openide.git
synced 2025-12-16 22:51:17 +07:00
replace with diamonds should always check if inferred type agrees with expected type (IDEA-73944)
This commit is contained in:
@@ -16,6 +16,7 @@ import com.intellij.util.containers.MultiMap;
|
||||
import junit.framework.Assert;
|
||||
import org.jetbrains.annotations.NonNls;
|
||||
|
||||
import java.util.ArrayList;
|
||||
import java.util.Collection;
|
||||
|
||||
/**
|
||||
@@ -253,6 +254,10 @@ public class IntroduceVariableTest extends LightCodeInsightTestCase {
|
||||
doTest(new MockIntroduceVariableHandler("a", true, true, true, "java.util.ArrayList<java.lang.String>"));
|
||||
}
|
||||
|
||||
public void testCantCollapsedToDiamond() throws Exception {
|
||||
doTest(new MockIntroduceVariableHandler("a", true, true, true, "Foo<java.lang.Number>"));
|
||||
}
|
||||
|
||||
public void testSiblingInnerClassType() throws Exception {
|
||||
doTest(new MockIntroduceVariableHandler("vari", true, false, false, "A.B") {
|
||||
@Override
|
||||
|
||||
Reference in New Issue
Block a user