[K/JS] Eliminate duplication of init block inside exported ES-classes ^KT-58246 Fixed

This commit is contained in:
Artem Kobzar
2023-04-25 16:21:08 +00:00
committed by Space Team
parent 9afddb1a7a
commit 27b103e2ca
7 changed files with 111 additions and 5 deletions
@@ -1848,6 +1848,12 @@ public class BoxJsTestGenerated extends AbstractBoxJsTest {
public void testAllFilesPresentInExport() throws Exception {
KtTestUtil.assertAllTestsPresentByMetadataWithExcluded(this.getClass(), new File("js/js.translator/testData/box/esModules/export"), Pattern.compile("^([^_](.+))\\.kt$"), null, TargetBackend.JS, true);
}
@Test
@TestMetadata("exportClassWithInitBlock.kt")
public void testExportClassWithInitBlock() throws Exception {
runTest("js/js.translator/testData/box/esModules/export/exportClassWithInitBlock.kt");
}
}
@Nested
@@ -2096,6 +2102,12 @@ public class BoxJsTestGenerated extends AbstractBoxJsTest {
runTest("js/js.translator/testData/box/export/exportClassPropertiesInDifferentCombinations.kt");
}
@Test
@TestMetadata("exportClassWithInitBlock.kt")
public void testExportClassWithInitBlock() throws Exception {
runTest("js/js.translator/testData/box/export/exportClassWithInitBlock.kt");
}
@Test
@TestMetadata("exportClassWithInternal.kt")
public void testExportClassWithInternal() throws Exception {
@@ -2189,6 +2189,12 @@ public class FirJsBoxTestGenerated extends AbstractFirJsBoxTest {
runTest("js/js.translator/testData/box/esModules/export/exportAllFile.kt");
}
@Test
@TestMetadata("exportClassWithInitBlock.kt")
public void testExportClassWithInitBlock() throws Exception {
runTest("js/js.translator/testData/box/esModules/export/exportClassWithInitBlock.kt");
}
@Test
@TestMetadata("exportEnumClass.kt")
public void testExportEnumClass() throws Exception {
@@ -2724,6 +2730,12 @@ public class FirJsBoxTestGenerated extends AbstractFirJsBoxTest {
runTest("js/js.translator/testData/box/export/exportClassPropertiesInDifferentCombinations.kt");
}
@Test
@TestMetadata("exportClassWithInitBlock.kt")
public void testExportClassWithInitBlock() throws Exception {
runTest("js/js.translator/testData/box/export/exportClassWithInitBlock.kt");
}
@Test
@TestMetadata("exportClassWithInternal.kt")
public void testExportClassWithInternal() throws Exception {
@@ -2295,6 +2295,12 @@ public class IrBoxJsES6TestGenerated extends AbstractIrBoxJsES6Test {
runTest("js/js.translator/testData/box/esModules/export/exportAllFile.kt");
}
@Test
@TestMetadata("exportClassWithInitBlock.kt")
public void testExportClassWithInitBlock() throws Exception {
runTest("js/js.translator/testData/box/esModules/export/exportClassWithInitBlock.kt");
}
@Test
@TestMetadata("exportEnumClass.kt")
public void testExportEnumClass() throws Exception {
@@ -2830,6 +2836,12 @@ public class IrBoxJsES6TestGenerated extends AbstractIrBoxJsES6Test {
runTest("js/js.translator/testData/box/export/exportClassPropertiesInDifferentCombinations.kt");
}
@Test
@TestMetadata("exportClassWithInitBlock.kt")
public void testExportClassWithInitBlock() throws Exception {
runTest("js/js.translator/testData/box/export/exportClassWithInitBlock.kt");
}
@Test
@TestMetadata("exportClassWithInternal.kt")
public void testExportClassWithInternal() throws Exception {
@@ -2189,6 +2189,12 @@ public class IrBoxJsTestGenerated extends AbstractIrBoxJsTest {
runTest("js/js.translator/testData/box/esModules/export/exportAllFile.kt");
}
@Test
@TestMetadata("exportClassWithInitBlock.kt")
public void testExportClassWithInitBlock() throws Exception {
runTest("js/js.translator/testData/box/esModules/export/exportClassWithInitBlock.kt");
}
@Test
@TestMetadata("exportEnumClass.kt")
public void testExportEnumClass() throws Exception {
@@ -2724,6 +2730,12 @@ public class IrBoxJsTestGenerated extends AbstractIrBoxJsTest {
runTest("js/js.translator/testData/box/export/exportClassPropertiesInDifferentCombinations.kt");
}
@Test
@TestMetadata("exportClassWithInitBlock.kt")
public void testExportClassWithInitBlock() throws Exception {
runTest("js/js.translator/testData/box/export/exportClassWithInitBlock.kt");
}
@Test
@TestMetadata("exportClassWithInternal.kt")
public void testExportClassWithInternal() throws Exception {