[JS IR IC] Add tests to check cache invalidation via fast path

This commit is contained in:
Roman Artemev
2021-12-13 17:18:38 +03:00
committed by teamcity
parent b719865c25
commit 312cbb6613
16 changed files with 78 additions and 0 deletions
@@ -30,6 +30,16 @@ public class InvalidationTestGenerated extends AbstractInvalidationTest {
KtTestUtil.assertAllTestsPresentByMetadataWithExcluded(this.getClass(), new File("js/js.translator/testData/incremental/invalidation"), Pattern.compile("^([^_](.+))$"), null, TargetBackend.JS_IR, false);
}
@TestMetadata("fastPath1")
public void testFastPath1() throws Exception {
runTest("js/js.translator/testData/incremental/invalidation/fastPath1/");
}
@TestMetadata("fastPath2")
public void testFastPath2() throws Exception {
runTest("js/js.translator/testData/incremental/invalidation/fastPath2/");
}
@TestMetadata("simple")
public void testSimple() throws Exception {
runTest("js/js.translator/testData/incremental/invalidation/simple/");
@@ -0,0 +1 @@
fun foo() = 42
@@ -0,0 +1,7 @@
STEP 0:
dependencies: stdlib
dirty: l1.kt
STEP 1:
dependencies: stdlib
dirty:
flags: FP
@@ -0,0 +1,2 @@
fun qux() = foo()
@@ -0,0 +1 @@
fun qux() = foo() + 2
@@ -0,0 +1,9 @@
STEP 0:
dependencies: stdlib, lib1
dirty: l2.kt
STEP 1:
dependencies: stdlib, lib1
modifications:
U : l2.kt.1 -> l2.kt
dirty: l2.kt
@@ -0,0 +1,2 @@
fun box() = qux()
@@ -0,0 +1,6 @@
STEP 0:
dependencies: stdlib, lib1, lib2
dirty: m.kt
STEP 1:
dependencies: stdlib, lib1, lib2
@@ -0,0 +1,7 @@
MODULES: lib1, lib2, main
STEP 0:
libs: lib1, lib2, main
STEP 1:
libs: lib1, lib2, main
@@ -0,0 +1 @@
fun foo() = 42
@@ -0,0 +1,7 @@
STEP 0:
dependencies: stdlib
dirty: l1.kt
STEP 1:
dependencies: stdlib
dirty:
flags: FP
@@ -0,0 +1,2 @@
fun qux() = foo()
@@ -0,0 +1,7 @@
STEP 0:
dependencies: stdlib, lib1
dirty: l2.kt
STEP 1:
dependencies: stdlib, lib1
flags: FP
@@ -0,0 +1,2 @@
fun box() = qux()
@@ -0,0 +1,7 @@
STEP 0:
dependencies: stdlib, lib1, lib2
dirty: m.kt
STEP 1:
dependencies: stdlib, lib1, lib2
flags: FP
@@ -0,0 +1,7 @@
MODULES: lib1, lib2, main
STEP 0:
libs: lib1, lib2, main
STEP 1:
libs: lib1, lib2, main