[FIR] Bring equivalent call behavior closer to K1

#KT-61159 Fixed
This commit is contained in:
Kirill Rakhman
2023-08-14 17:01:29 +02:00
committed by Space Team
parent 7c67e9e08b
commit fa77e3952d
39 changed files with 408 additions and 126 deletions
@@ -13178,6 +13178,22 @@ public class FirJsCodegenBoxTestGenerated extends AbstractFirJsCodegenBoxTest {
}
}
@Nested
@TestMetadata("compiler/testData/codegen/box/equivalentCalls")
@TestDataPath("$PROJECT_ROOT")
public class EquivalentCalls {
@Test
public void testAllFilesPresentInEquivalentCalls() throws Exception {
KtTestUtil.assertAllTestsPresentByMetadataWithExcluded(this.getClass(), new File("compiler/testData/codegen/box/equivalentCalls"), Pattern.compile("^(.+)\\.kt$"), null, TargetBackend.JS_IR, true);
}
@Test
@TestMetadata("localEquivalentWins.kt")
public void testLocalEquivalentWins() throws Exception {
runTest("compiler/testData/codegen/box/equivalentCalls/localEquivalentWins.kt");
}
}
@Nested
@TestMetadata("compiler/testData/codegen/box/evaluate")
@TestDataPath("$PROJECT_ROOT")
@@ -13178,6 +13178,22 @@ public class FirJsES6CodegenBoxTestGenerated extends AbstractFirJsES6CodegenBoxT
}
}
@Nested
@TestMetadata("compiler/testData/codegen/box/equivalentCalls")
@TestDataPath("$PROJECT_ROOT")
public class EquivalentCalls {
@Test
public void testAllFilesPresentInEquivalentCalls() throws Exception {
KtTestUtil.assertAllTestsPresentByMetadataWithExcluded(this.getClass(), new File("compiler/testData/codegen/box/equivalentCalls"), Pattern.compile("^(.+)\\.kt$"), null, TargetBackend.JS_IR_ES6, true);
}
@Test
@TestMetadata("localEquivalentWins.kt")
public void testLocalEquivalentWins() throws Exception {
runTest("compiler/testData/codegen/box/equivalentCalls/localEquivalentWins.kt");
}
}
@Nested
@TestMetadata("compiler/testData/codegen/box/evaluate")
@TestDataPath("$PROJECT_ROOT")
@@ -13178,6 +13178,22 @@ public class IrJsCodegenBoxTestGenerated extends AbstractIrJsCodegenBoxTest {
}
}
@Nested
@TestMetadata("compiler/testData/codegen/box/equivalentCalls")
@TestDataPath("$PROJECT_ROOT")
public class EquivalentCalls {
@Test
public void testAllFilesPresentInEquivalentCalls() throws Exception {
KtTestUtil.assertAllTestsPresentByMetadataWithExcluded(this.getClass(), new File("compiler/testData/codegen/box/equivalentCalls"), Pattern.compile("^(.+)\\.kt$"), null, TargetBackend.JS_IR, true);
}
@Test
@TestMetadata("localEquivalentWins.kt")
public void testLocalEquivalentWins() throws Exception {
runTest("compiler/testData/codegen/box/equivalentCalls/localEquivalentWins.kt");
}
}
@Nested
@TestMetadata("compiler/testData/codegen/box/evaluate")
@TestDataPath("$PROJECT_ROOT")
@@ -13178,6 +13178,22 @@ public class IrJsES6CodegenBoxTestGenerated extends AbstractIrJsES6CodegenBoxTes
}
}
@Nested
@TestMetadata("compiler/testData/codegen/box/equivalentCalls")
@TestDataPath("$PROJECT_ROOT")
public class EquivalentCalls {
@Test
public void testAllFilesPresentInEquivalentCalls() throws Exception {
KtTestUtil.assertAllTestsPresentByMetadataWithExcluded(this.getClass(), new File("compiler/testData/codegen/box/equivalentCalls"), Pattern.compile("^(.+)\\.kt$"), null, TargetBackend.JS_IR_ES6, true);
}
@Test
@TestMetadata("localEquivalentWins.kt")
public void testLocalEquivalentWins() throws Exception {
runTest("compiler/testData/codegen/box/equivalentCalls/localEquivalentWins.kt");
}
}
@Nested
@TestMetadata("compiler/testData/codegen/box/evaluate")
@TestDataPath("$PROJECT_ROOT")