IfThenToSafeAccessInspection: fix it works correctly for variable/operator call

#KT-30513 Fixed
#KT-17071 Fixed
This commit is contained in:
Toshiaki Kameyama
2020-01-06 17:49:29 +09:00
committed by Yan Zhulanow
parent 871ad2b909
commit 5095caee50
11 changed files with 107 additions and 2 deletions
@@ -522,6 +522,26 @@ public class LocalInspectionTestGenerated extends AbstractLocalInspectionTest {
runTest("idea/testData/inspectionsLocal/branched/ifThenToSafeAccess/call4.kt");
}
@TestMetadata("callInvokeOperator.kt")
public void testCallInvokeOperator() throws Exception {
runTest("idea/testData/inspectionsLocal/branched/ifThenToSafeAccess/callInvokeOperator.kt");
}
@TestMetadata("callInvokeOperator2.kt")
public void testCallInvokeOperator2() throws Exception {
runTest("idea/testData/inspectionsLocal/branched/ifThenToSafeAccess/callInvokeOperator2.kt");
}
@TestMetadata("callVariable.kt")
public void testCallVariable() throws Exception {
runTest("idea/testData/inspectionsLocal/branched/ifThenToSafeAccess/callVariable.kt");
}
@TestMetadata("callVariable2.kt")
public void testCallVariable2() throws Exception {
runTest("idea/testData/inspectionsLocal/branched/ifThenToSafeAccess/callVariable2.kt");
}
@TestMetadata("conditionComparesNullWithNull.kt")
public void testConditionComparesNullWithNull() throws Exception {
runTest("idea/testData/inspectionsLocal/branched/ifThenToSafeAccess/conditionComparesNullWithNull.kt");