Change Signature: enable on primary constructor keyword (#2482)

#KT-19744 Fixed
This commit is contained in:
Toshiaki Kameyama
2020-06-11 18:10:12 +09:00
committed by GitHub
parent 957a927790
commit cbbdec5898
4 changed files with 65 additions and 0 deletions
@@ -808,6 +808,20 @@ class KotlinChangeSignatureTest : KotlinLightCodeInsightFixtureTestCase() {
}
}
fun testPrimaryConstructorOnConstructorKeyword() = doTest {
val defaultValueForCall = KtPsiFactory(project).createExpression("\"foo\"")
addParameter(
KotlinParameterInfo(
originalBaseFunctionDescriptor,
-1,
"s",
KotlinTypeInfo(false, BUILT_INS.stringType),
null,
defaultValueForCall
)
)
}
fun testJavaConstructorInDelegationCall() {
doJavaTest { newParameters.add(ParameterInfoImpl(-1, "s", stringPsiType, "\"foo\"")) }
}