[JS IR] Add tests for JS IR IC + PL

^KT-57347 related
This commit is contained in:
Alexander Korepanov
2023-05-08 16:54:30 +02:00
committed by Space Team
parent 97620030c6
commit 82a1242f22
96 changed files with 710 additions and 3 deletions
@@ -0,0 +1 @@
fun foo() = 0
@@ -0,0 +1 @@
fun bar() = 77
@@ -0,0 +1 @@
fun foo() = 2
@@ -0,0 +1,14 @@
STEP 0:
modifications:
U : l1.0.kt -> l1.kt
added file: l1.kt
STEP 1:
modifications:
U : l1.1.kt -> l1.kt
modified ir: l1.kt
updated exports: l1.kt
STEP 2:
modifications:
U : l1.2.kt -> l1.kt
modified ir: l1.kt
updated exports: l1.kt
@@ -0,0 +1 @@
inline fun inlineFun() = foo()
@@ -0,0 +1,7 @@
STEP 0:
dependencies: lib1
added file: l2.kt
STEP 1..2:
dependencies: lib1
rebuild klib: false
updated imports: l2.kt
@@ -0,0 +1,5 @@
fun box(stepId: Int): String {
val x = test()
if (x != stepId) return "Fail; got $x"
return "OK"
}
@@ -0,0 +1,7 @@
STEP 0:
dependencies: lib1, lib2
added file: m.kt, test.kt
STEP 1..2:
dependencies: lib1, lib2
rebuild klib: false
updated imports: test.kt
@@ -0,0 +1,7 @@
fun test(): Int {
try {
return inlineFun()
} catch (e: Error) {
return 1
}
}
@@ -0,0 +1,5 @@
MODULES: lib1, lib2, main
STEP 0..2:
libs: lib1, lib2, main
dirty js: lib1, lib2, main