[IR SERIALIZATION] Add tests about klib linkage
This commit is contained in:
+10
@@ -5339,6 +5339,16 @@ public class IrBoxJsTestGenerated extends AbstractIrBoxJsTest {
|
||||
KotlinTestUtils.assertAllTestsPresentByMetadata(this.getClass(), new File("js/js.translator/testData/box/multiModule"), Pattern.compile("^([^_](.+))\\.kt$"), TargetBackend.JS_IR, true);
|
||||
}
|
||||
|
||||
@TestMetadata("clashedDeclLinkage.kt")
|
||||
public void testClashedDeclLinkage() throws Exception {
|
||||
runTest("js/js.translator/testData/box/multiModule/clashedDeclLinkage.kt");
|
||||
}
|
||||
|
||||
@TestMetadata("clashedInternalDeclarations.kt")
|
||||
public void testClashedInternalDeclarations() throws Exception {
|
||||
runTest("js/js.translator/testData/box/multiModule/clashedInternalDeclarations.kt");
|
||||
}
|
||||
|
||||
@TestMetadata("interfaceMethodWithDefaultParameter.kt")
|
||||
public void testInterfaceMethodWithDefaultParameter() throws Exception {
|
||||
runTest("js/js.translator/testData/box/multiModule/interfaceMethodWithDefaultParameter.kt");
|
||||
|
||||
+10
@@ -5354,6 +5354,16 @@ public class BoxJsTestGenerated extends AbstractBoxJsTest {
|
||||
KotlinTestUtils.assertAllTestsPresentByMetadata(this.getClass(), new File("js/js.translator/testData/box/multiModule"), Pattern.compile("^([^_](.+))\\.kt$"), TargetBackend.JS, true);
|
||||
}
|
||||
|
||||
@TestMetadata("clashedDeclLinkage.kt")
|
||||
public void testClashedDeclLinkage() throws Exception {
|
||||
runTest("js/js.translator/testData/box/multiModule/clashedDeclLinkage.kt");
|
||||
}
|
||||
|
||||
@TestMetadata("clashedInternalDeclarations.kt")
|
||||
public void testClashedInternalDeclarations() throws Exception {
|
||||
runTest("js/js.translator/testData/box/multiModule/clashedInternalDeclarations.kt");
|
||||
}
|
||||
|
||||
@TestMetadata("interfaceMethodWithDefaultParameter.kt")
|
||||
public void testInterfaceMethodWithDefaultParameter() throws Exception {
|
||||
runTest("js/js.translator/testData/box/multiModule/interfaceMethodWithDefaultParameter.kt");
|
||||
|
||||
@@ -0,0 +1,41 @@
|
||||
// KJS_WITH_FULL_RUNTIME
|
||||
|
||||
// MODULE: AT
|
||||
// FILE: at.kt
|
||||
package foo
|
||||
|
||||
fun ooo(): String = "O"
|
||||
fun kkk(): String = "Fail AT"
|
||||
|
||||
// MODULE: A(AT)
|
||||
// FILE: a.kt
|
||||
package bar
|
||||
|
||||
import foo.*
|
||||
|
||||
fun o(): String = ooo()
|
||||
|
||||
// MODULE: BT
|
||||
// FILE: bt.kt
|
||||
package foo
|
||||
|
||||
fun ooo(): String = "Fail BT"
|
||||
fun kkk(): String = "K"
|
||||
|
||||
// MODULE: B(BT)
|
||||
// FILE: b.kt
|
||||
package bar
|
||||
|
||||
import foo.*
|
||||
|
||||
fun k(): String = kkk()
|
||||
|
||||
// MODULE: main(A, B)
|
||||
// FILE: main.kt
|
||||
package main
|
||||
|
||||
import bar.*
|
||||
|
||||
fun box(): String {
|
||||
return o() + k()
|
||||
}
|
||||
@@ -0,0 +1,41 @@
|
||||
// KJS_WITH_FULL_RUNTIME
|
||||
|
||||
// MODULE: AT
|
||||
// FILE: at.kt
|
||||
package foo
|
||||
|
||||
internal fun qqq() = "Fail AT"
|
||||
|
||||
// MODULE: A(AT)
|
||||
// FILE: a.kt
|
||||
package foo
|
||||
|
||||
internal fun qqq() = "O"
|
||||
|
||||
fun o(): String = qqq()
|
||||
|
||||
// MODULE: BT
|
||||
// FILE: bt.kt
|
||||
package foo
|
||||
|
||||
internal fun qqq() = "K"
|
||||
|
||||
fun ik() = qqq()
|
||||
|
||||
// MODULE: B(BT)
|
||||
// FILE: b.kt
|
||||
package foo
|
||||
|
||||
internal fun qqq() = "Fail B"
|
||||
|
||||
fun k(): String = ik()
|
||||
|
||||
// MODULE: main(A, B)
|
||||
// FILE: main.kt
|
||||
package main
|
||||
|
||||
import foo.*
|
||||
|
||||
fun box(): String {
|
||||
return o() + k()
|
||||
}
|
||||
Reference in New Issue
Block a user