[PL][JS] Add test for handling external declarations

^KT-57378
This commit is contained in:
Dmitriy Dolovov
2023-04-20 16:41:58 +02:00
committed by Space Team
parent 4afc5315ca
commit b5ad5edc08
17 changed files with 203 additions and 3 deletions
@@ -62,6 +62,12 @@ public class FirNativePartialLinkageTestGenerated extends AbstractNativePartialL
runTest("compiler/testData/klibABI/classTransformations/");
}
@Test
@TestMetadata("externalDeclarations")
public void testExternalDeclarations() throws Exception {
runTest("compiler/testData/klibABI/externalDeclarations/");
}
@Test
@TestMetadata("functionTransformations")
public void testFunctionTransformations() throws Exception {
@@ -60,6 +60,12 @@ public class NativePartialLinkageTestGenerated extends AbstractNativePartialLink
runTest("compiler/testData/klibABI/classTransformations/");
}
@Test
@TestMetadata("externalDeclarations")
public void testExternalDeclarations() throws Exception {
runTest("compiler/testData/klibABI/externalDeclarations/");
}
@Test
@TestMetadata("functionTransformations")
public void testFunctionTransformations() throws Exception {
@@ -57,9 +57,14 @@ abstract class AbstractNativePartialLinkageTest : AbstractNativeSimpleTest() {
override fun onNonEmptyBuildDirectory(directory: File) = backupDirectoryContents(directory)
// Temporarily mute TA tests on FIR FE with caches.
override fun isIgnoredTest(projectInfo: ProjectInfo) = super.isIgnoredTest(projectInfo)
|| (projectInfo.name == "typeAliasChanges" && testModeName.endsWith("STATIC_EVERYWHERE")
&& this@AbstractNativePartialLinkageTest::class.java.simpleName.startsWith("Fir"))
override fun isIgnoredTest(projectInfo: ProjectInfo) = when {
super.isIgnoredTest(projectInfo) -> true
projectInfo.name == "typeAliasChanges"
&& testModeName.endsWith("STATIC_EVERYWHERE")
&& this@AbstractNativePartialLinkageTest::class.java.simpleName.startsWith("Fir") -> true
projectInfo.name == "externalDeclarations" -> true
else -> false
}
override fun onIgnoredTest() = throw TestAbortedException()
}