Extract Function: Add test for ===
#KT-7663 Fixed
This commit is contained in:
@@ -0,0 +1,9 @@
|
||||
// SUGGESTED_NAMES: b, getT
|
||||
// PARAM_DESCRIPTOR: value-parameter val a: kotlin.Int defined in test
|
||||
// PARAM_DESCRIPTOR: value-parameter val b: kotlin.Int defined in test
|
||||
// PARAM_TYPES: kotlin.Int, Number, Comparable<Int>, Any
|
||||
// PARAM_TYPES: kotlin.Int, Number, Comparable<Int>, Any
|
||||
|
||||
fun test(a: Int, b: Int): Boolean {
|
||||
val t = <selection>a === b</selection>
|
||||
}
|
||||
@@ -0,0 +1,11 @@
|
||||
// SUGGESTED_NAMES: b, getT
|
||||
// PARAM_DESCRIPTOR: value-parameter val a: kotlin.Int defined in test
|
||||
// PARAM_DESCRIPTOR: value-parameter val b: kotlin.Int defined in test
|
||||
// PARAM_TYPES: kotlin.Int, Number, Comparable<Int>, Any
|
||||
// PARAM_TYPES: kotlin.Int, Number, Comparable<Int>, Any
|
||||
|
||||
fun test(a: Int, b: Int): Boolean {
|
||||
val t = b(a, b)
|
||||
}
|
||||
|
||||
private fun b(a: Int, b: Int) = a === b
|
||||
+6
@@ -366,6 +366,12 @@ public class JetExtractionTestGenerated extends AbstractJetExtractionTest {
|
||||
doExtractFunctionTest(fileName);
|
||||
}
|
||||
|
||||
@TestMetadata("identityEquals.kt")
|
||||
public void testIdentityEquals() throws Exception {
|
||||
String fileName = JetTestUtils.navigationMetadata("idea/testData/refactoring/extractFunction/basic/identityEquals.kt");
|
||||
doExtractFunctionTest(fileName);
|
||||
}
|
||||
|
||||
@TestMetadata("invisibleType.kt")
|
||||
public void testInvisibleType() throws Exception {
|
||||
String fileName = JetTestUtils.navigationMetadata("idea/testData/refactoring/extractFunction/basic/invisibleType.kt");
|
||||
|
||||
Reference in New Issue
Block a user