Add test for KT-52338 (fixed together with KT-49507)

This commit is contained in:
Mikhail Glukhikh
2022-06-17 12:26:40 +02:00
committed by teamcity
parent 66d344975b
commit 6a3be0d8ac
3 changed files with 30 additions and 0 deletions
@@ -17347,6 +17347,12 @@ public class FirBlackBoxCodegenTestGenerated extends AbstractFirBlackBoxCodegenT
runTest("compiler/testData/codegen/box/fieldRename/genericPropertyWithItself.kt");
}
@Test
@TestMetadata("javaFieldAndCompanionProperty.kt")
public void testJavaFieldAndCompanionProperty() throws Exception {
runTest("compiler/testData/codegen/box/fieldRename/javaFieldAndCompanionProperty.kt");
}
@Test
@TestMetadata("javaFieldAndKotlinProperty.kt")
public void testJavaFieldAndKotlinProperty() throws Exception {
@@ -0,0 +1,18 @@
// TARGET_BACKEND: JVM_IR
// FILE: Base.java
public class Base {
protected String TAG = "OK";
}
// FILE: Sub.kt
class Sub : Base() {
companion object {
val TAG = "FAIL"
}
fun log() = TAG
}
fun box() = Sub().log()
@@ -17347,6 +17347,12 @@ public class IrBlackBoxCodegenTestGenerated extends AbstractIrBlackBoxCodegenTes
runTest("compiler/testData/codegen/box/fieldRename/genericPropertyWithItself.kt");
}
@Test
@TestMetadata("javaFieldAndCompanionProperty.kt")
public void testJavaFieldAndCompanionProperty() throws Exception {
runTest("compiler/testData/codegen/box/fieldRename/javaFieldAndCompanionProperty.kt");
}
@Test
@TestMetadata("javaFieldAndKotlinProperty.kt")
public void testJavaFieldAndKotlinProperty() throws Exception {