[K/N][Tests] Migrate some cinterop tests to new infra

^KT-61259
This commit is contained in:
Vladimir Sukharev
2024-01-04 19:01:46 +01:00
committed by Space Team
parent 422128f3dc
commit bf01cb16b4
63 changed files with 1776 additions and 1025 deletions
@@ -4867,6 +4867,128 @@ public class FirNativeCodegenBoxTestGenerated extends AbstractNativeCodegenBoxTe
public void testToKString() throws Exception {
runTest("compiler/testData/codegen/box/cinterop/toKString.kt");
}
@Nested
@TestMetadata("compiler/testData/codegen/box/cinterop/basics")
@TestDataPath("$PROJECT_ROOT")
@Tag("frontend-fir")
@FirPipeline()
@UseExtTestCaseGroupProvider()
public class Basics {
@Test
@TestMetadata("1.kt")
public void test1() throws Exception {
runTest("compiler/testData/codegen/box/cinterop/basics/1.kt");
}
@Test
@TestMetadata("3.kt")
public void test3() throws Exception {
runTest("compiler/testData/codegen/box/cinterop/basics/3.kt");
}
@Test
public void testAllFilesPresentInBasics() throws Exception {
KtTestUtil.assertAllTestsPresentByMetadataWithExcluded(this.getClass(), new File("compiler/testData/codegen/box/cinterop/basics"), Pattern.compile("^(.+)\\.kt$"), null, TargetBackend.NATIVE, true);
}
@Test
@TestMetadata("available_processors.kt")
public void testAvailable_processors() throws Exception {
runTest("compiler/testData/codegen/box/cinterop/basics/available_processors.kt");
}
@Test
@TestMetadata("macros.kt")
public void testMacros() throws Exception {
runTest("compiler/testData/codegen/box/cinterop/basics/macros.kt");
}
@Test
@TestMetadata("mangling.kt")
public void testMangling() throws Exception {
runTest("compiler/testData/codegen/box/cinterop/basics/mangling.kt");
}
@Test
@TestMetadata("mangling2.kt")
public void testMangling2() throws Exception {
runTest("compiler/testData/codegen/box/cinterop/basics/mangling2.kt");
}
@Test
@TestMetadata("mangling_keywords.kt")
public void testMangling_keywords() throws Exception {
runTest("compiler/testData/codegen/box/cinterop/basics/mangling_keywords.kt");
}
@Test
@TestMetadata("mangling_keywords2.kt")
public void testMangling_keywords2() throws Exception {
runTest("compiler/testData/codegen/box/cinterop/basics/mangling_keywords2.kt");
}
@Test
@TestMetadata("structAnonym.kt")
public void testStructAnonym() throws Exception {
runTest("compiler/testData/codegen/box/cinterop/basics/structAnonym.kt");
}
@Test
@TestMetadata("structs.kt")
public void testStructs() throws Exception {
runTest("compiler/testData/codegen/box/cinterop/basics/structs.kt");
}
@Test
@TestMetadata("types.kt")
public void testTypes() throws Exception {
runTest("compiler/testData/codegen/box/cinterop/basics/types.kt");
}
@Test
@TestMetadata("union.kt")
public void testUnion() throws Exception {
runTest("compiler/testData/codegen/box/cinterop/basics/union.kt");
}
@Test
@TestMetadata("unsupported.kt")
public void testUnsupported() throws Exception {
runTest("compiler/testData/codegen/box/cinterop/basics/unsupported.kt");
}
@Test
@TestMetadata("values.kt")
public void testValues() throws Exception {
runTest("compiler/testData/codegen/box/cinterop/basics/values.kt");
}
@Test
@TestMetadata("vectors.kt")
public void testVectors() throws Exception {
runTest("compiler/testData/codegen/box/cinterop/basics/vectors.kt");
}
}
@Nested
@TestMetadata("compiler/testData/codegen/box/cinterop/exceptions")
@TestDataPath("$PROJECT_ROOT")
@Tag("frontend-fir")
@FirPipeline()
@UseExtTestCaseGroupProvider()
public class Exceptions {
@Test
public void testAllFilesPresentInExceptions() throws Exception {
KtTestUtil.assertAllTestsPresentByMetadataWithExcluded(this.getClass(), new File("compiler/testData/codegen/box/cinterop/exceptions"), Pattern.compile("^(.+)\\.kt$"), null, TargetBackend.NATIVE, true);
}
@Test
@TestMetadata("cCallback.kt")
public void testCCallback() throws Exception {
runTest("compiler/testData/codegen/box/cinterop/exceptions/cCallback.kt");
}
}
}
@Nested
@@ -4977,6 +4977,132 @@ public class FirNativeCodegenBoxTestNoPLGenerated extends AbstractNativeCodegenB
public void testToKString() throws Exception {
runTest("compiler/testData/codegen/box/cinterop/toKString.kt");
}
@Nested
@TestMetadata("compiler/testData/codegen/box/cinterop/basics")
@TestDataPath("$PROJECT_ROOT")
@Tag("frontend-fir")
@FirPipeline()
@UseExtTestCaseGroupProvider()
@UsePartialLinkage(mode = Mode.DISABLED)
@Tag("no-partial-linkage-may-be-skipped")
public class Basics {
@Test
@TestMetadata("1.kt")
public void test1() throws Exception {
runTest("compiler/testData/codegen/box/cinterop/basics/1.kt");
}
@Test
@TestMetadata("3.kt")
public void test3() throws Exception {
runTest("compiler/testData/codegen/box/cinterop/basics/3.kt");
}
@Test
public void testAllFilesPresentInBasics() throws Exception {
KtTestUtil.assertAllTestsPresentByMetadataWithExcluded(this.getClass(), new File("compiler/testData/codegen/box/cinterop/basics"), Pattern.compile("^(.+)\\.kt$"), null, TargetBackend.NATIVE, true);
}
@Test
@TestMetadata("available_processors.kt")
public void testAvailable_processors() throws Exception {
runTest("compiler/testData/codegen/box/cinterop/basics/available_processors.kt");
}
@Test
@TestMetadata("macros.kt")
public void testMacros() throws Exception {
runTest("compiler/testData/codegen/box/cinterop/basics/macros.kt");
}
@Test
@TestMetadata("mangling.kt")
public void testMangling() throws Exception {
runTest("compiler/testData/codegen/box/cinterop/basics/mangling.kt");
}
@Test
@TestMetadata("mangling2.kt")
public void testMangling2() throws Exception {
runTest("compiler/testData/codegen/box/cinterop/basics/mangling2.kt");
}
@Test
@TestMetadata("mangling_keywords.kt")
public void testMangling_keywords() throws Exception {
runTest("compiler/testData/codegen/box/cinterop/basics/mangling_keywords.kt");
}
@Test
@TestMetadata("mangling_keywords2.kt")
public void testMangling_keywords2() throws Exception {
runTest("compiler/testData/codegen/box/cinterop/basics/mangling_keywords2.kt");
}
@Test
@TestMetadata("structAnonym.kt")
public void testStructAnonym() throws Exception {
runTest("compiler/testData/codegen/box/cinterop/basics/structAnonym.kt");
}
@Test
@TestMetadata("structs.kt")
public void testStructs() throws Exception {
runTest("compiler/testData/codegen/box/cinterop/basics/structs.kt");
}
@Test
@TestMetadata("types.kt")
public void testTypes() throws Exception {
runTest("compiler/testData/codegen/box/cinterop/basics/types.kt");
}
@Test
@TestMetadata("union.kt")
public void testUnion() throws Exception {
runTest("compiler/testData/codegen/box/cinterop/basics/union.kt");
}
@Test
@TestMetadata("unsupported.kt")
public void testUnsupported() throws Exception {
runTest("compiler/testData/codegen/box/cinterop/basics/unsupported.kt");
}
@Test
@TestMetadata("values.kt")
public void testValues() throws Exception {
runTest("compiler/testData/codegen/box/cinterop/basics/values.kt");
}
@Test
@TestMetadata("vectors.kt")
public void testVectors() throws Exception {
runTest("compiler/testData/codegen/box/cinterop/basics/vectors.kt");
}
}
@Nested
@TestMetadata("compiler/testData/codegen/box/cinterop/exceptions")
@TestDataPath("$PROJECT_ROOT")
@Tag("frontend-fir")
@FirPipeline()
@UseExtTestCaseGroupProvider()
@UsePartialLinkage(mode = Mode.DISABLED)
@Tag("no-partial-linkage-may-be-skipped")
public class Exceptions {
@Test
public void testAllFilesPresentInExceptions() throws Exception {
KtTestUtil.assertAllTestsPresentByMetadataWithExcluded(this.getClass(), new File("compiler/testData/codegen/box/cinterop/exceptions"), Pattern.compile("^(.+)\\.kt$"), null, TargetBackend.NATIVE, true);
}
@Test
@TestMetadata("cCallback.kt")
public void testCCallback() throws Exception {
runTest("compiler/testData/codegen/box/cinterop/exceptions/cCallback.kt");
}
}
}
@Nested
@@ -4757,6 +4757,124 @@ public class NativeCodegenBoxTestGenerated extends AbstractNativeCodegenBoxTest
public void testToKString() throws Exception {
runTest("compiler/testData/codegen/box/cinterop/toKString.kt");
}
@Nested
@TestMetadata("compiler/testData/codegen/box/cinterop/basics")
@TestDataPath("$PROJECT_ROOT")
@UseExtTestCaseGroupProvider()
public class Basics {
@Test
@TestMetadata("1.kt")
public void test1() throws Exception {
runTest("compiler/testData/codegen/box/cinterop/basics/1.kt");
}
@Test
@TestMetadata("3.kt")
public void test3() throws Exception {
runTest("compiler/testData/codegen/box/cinterop/basics/3.kt");
}
@Test
public void testAllFilesPresentInBasics() throws Exception {
KtTestUtil.assertAllTestsPresentByMetadataWithExcluded(this.getClass(), new File("compiler/testData/codegen/box/cinterop/basics"), Pattern.compile("^(.+)\\.kt$"), null, TargetBackend.NATIVE, true);
}
@Test
@TestMetadata("available_processors.kt")
public void testAvailable_processors() throws Exception {
runTest("compiler/testData/codegen/box/cinterop/basics/available_processors.kt");
}
@Test
@TestMetadata("macros.kt")
public void testMacros() throws Exception {
runTest("compiler/testData/codegen/box/cinterop/basics/macros.kt");
}
@Test
@TestMetadata("mangling.kt")
public void testMangling() throws Exception {
runTest("compiler/testData/codegen/box/cinterop/basics/mangling.kt");
}
@Test
@TestMetadata("mangling2.kt")
public void testMangling2() throws Exception {
runTest("compiler/testData/codegen/box/cinterop/basics/mangling2.kt");
}
@Test
@TestMetadata("mangling_keywords.kt")
public void testMangling_keywords() throws Exception {
runTest("compiler/testData/codegen/box/cinterop/basics/mangling_keywords.kt");
}
@Test
@TestMetadata("mangling_keywords2.kt")
public void testMangling_keywords2() throws Exception {
runTest("compiler/testData/codegen/box/cinterop/basics/mangling_keywords2.kt");
}
@Test
@TestMetadata("structAnonym.kt")
public void testStructAnonym() throws Exception {
runTest("compiler/testData/codegen/box/cinterop/basics/structAnonym.kt");
}
@Test
@TestMetadata("structs.kt")
public void testStructs() throws Exception {
runTest("compiler/testData/codegen/box/cinterop/basics/structs.kt");
}
@Test
@TestMetadata("types.kt")
public void testTypes() throws Exception {
runTest("compiler/testData/codegen/box/cinterop/basics/types.kt");
}
@Test
@TestMetadata("union.kt")
public void testUnion() throws Exception {
runTest("compiler/testData/codegen/box/cinterop/basics/union.kt");
}
@Test
@TestMetadata("unsupported.kt")
public void testUnsupported() throws Exception {
runTest("compiler/testData/codegen/box/cinterop/basics/unsupported.kt");
}
@Test
@TestMetadata("values.kt")
public void testValues() throws Exception {
runTest("compiler/testData/codegen/box/cinterop/basics/values.kt");
}
@Test
@TestMetadata("vectors.kt")
public void testVectors() throws Exception {
runTest("compiler/testData/codegen/box/cinterop/basics/vectors.kt");
}
}
@Nested
@TestMetadata("compiler/testData/codegen/box/cinterop/exceptions")
@TestDataPath("$PROJECT_ROOT")
@UseExtTestCaseGroupProvider()
public class Exceptions {
@Test
public void testAllFilesPresentInExceptions() throws Exception {
KtTestUtil.assertAllTestsPresentByMetadataWithExcluded(this.getClass(), new File("compiler/testData/codegen/box/cinterop/exceptions"), Pattern.compile("^(.+)\\.kt$"), null, TargetBackend.NATIVE, true);
}
@Test
@TestMetadata("cCallback.kt")
public void testCCallback() throws Exception {
runTest("compiler/testData/codegen/box/cinterop/exceptions/cCallback.kt");
}
}
}
@Nested
@@ -4868,6 +4868,128 @@ public class NativeCodegenBoxTestNoPLGenerated extends AbstractNativeCodegenBoxT
public void testToKString() throws Exception {
runTest("compiler/testData/codegen/box/cinterop/toKString.kt");
}
@Nested
@TestMetadata("compiler/testData/codegen/box/cinterop/basics")
@TestDataPath("$PROJECT_ROOT")
@UseExtTestCaseGroupProvider()
@UsePartialLinkage(mode = Mode.DISABLED)
@Tag("no-partial-linkage-may-be-skipped")
public class Basics {
@Test
@TestMetadata("1.kt")
public void test1() throws Exception {
runTest("compiler/testData/codegen/box/cinterop/basics/1.kt");
}
@Test
@TestMetadata("3.kt")
public void test3() throws Exception {
runTest("compiler/testData/codegen/box/cinterop/basics/3.kt");
}
@Test
public void testAllFilesPresentInBasics() throws Exception {
KtTestUtil.assertAllTestsPresentByMetadataWithExcluded(this.getClass(), new File("compiler/testData/codegen/box/cinterop/basics"), Pattern.compile("^(.+)\\.kt$"), null, TargetBackend.NATIVE, true);
}
@Test
@TestMetadata("available_processors.kt")
public void testAvailable_processors() throws Exception {
runTest("compiler/testData/codegen/box/cinterop/basics/available_processors.kt");
}
@Test
@TestMetadata("macros.kt")
public void testMacros() throws Exception {
runTest("compiler/testData/codegen/box/cinterop/basics/macros.kt");
}
@Test
@TestMetadata("mangling.kt")
public void testMangling() throws Exception {
runTest("compiler/testData/codegen/box/cinterop/basics/mangling.kt");
}
@Test
@TestMetadata("mangling2.kt")
public void testMangling2() throws Exception {
runTest("compiler/testData/codegen/box/cinterop/basics/mangling2.kt");
}
@Test
@TestMetadata("mangling_keywords.kt")
public void testMangling_keywords() throws Exception {
runTest("compiler/testData/codegen/box/cinterop/basics/mangling_keywords.kt");
}
@Test
@TestMetadata("mangling_keywords2.kt")
public void testMangling_keywords2() throws Exception {
runTest("compiler/testData/codegen/box/cinterop/basics/mangling_keywords2.kt");
}
@Test
@TestMetadata("structAnonym.kt")
public void testStructAnonym() throws Exception {
runTest("compiler/testData/codegen/box/cinterop/basics/structAnonym.kt");
}
@Test
@TestMetadata("structs.kt")
public void testStructs() throws Exception {
runTest("compiler/testData/codegen/box/cinterop/basics/structs.kt");
}
@Test
@TestMetadata("types.kt")
public void testTypes() throws Exception {
runTest("compiler/testData/codegen/box/cinterop/basics/types.kt");
}
@Test
@TestMetadata("union.kt")
public void testUnion() throws Exception {
runTest("compiler/testData/codegen/box/cinterop/basics/union.kt");
}
@Test
@TestMetadata("unsupported.kt")
public void testUnsupported() throws Exception {
runTest("compiler/testData/codegen/box/cinterop/basics/unsupported.kt");
}
@Test
@TestMetadata("values.kt")
public void testValues() throws Exception {
runTest("compiler/testData/codegen/box/cinterop/basics/values.kt");
}
@Test
@TestMetadata("vectors.kt")
public void testVectors() throws Exception {
runTest("compiler/testData/codegen/box/cinterop/basics/vectors.kt");
}
}
@Nested
@TestMetadata("compiler/testData/codegen/box/cinterop/exceptions")
@TestDataPath("$PROJECT_ROOT")
@UseExtTestCaseGroupProvider()
@UsePartialLinkage(mode = Mode.DISABLED)
@Tag("no-partial-linkage-may-be-skipped")
public class Exceptions {
@Test
public void testAllFilesPresentInExceptions() throws Exception {
KtTestUtil.assertAllTestsPresentByMetadataWithExcluded(this.getClass(), new File("compiler/testData/codegen/box/cinterop/exceptions"), Pattern.compile("^(.+)\\.kt$"), null, TargetBackend.NATIVE, true);
}
@Test
@TestMetadata("cCallback.kt")
public void testCCallback() throws Exception {
runTest("compiler/testData/codegen/box/cinterop/exceptions/cCallback.kt");
}
}
}
@Nested