[K/N] Adjust moved special backend checks tests
^KT-61564
This commit is contained in:
committed by
Space Team
parent
8f12bf6cc8
commit
08bc0a6bd0
+1
-1
@@ -21,7 +21,7 @@ import java.util.regex.Pattern;
|
||||
public class DiagnosticsNativeTestGenerated extends AbstractDiagnosticsNativeTest {
|
||||
@Test
|
||||
public void testAllFilesPresentInNativeTests() throws Exception {
|
||||
KtTestUtil.assertAllTestsPresentByMetadataWithExcluded(this.getClass(), new File("compiler/testData/diagnostics/nativeTests"), Pattern.compile("^(.+)\\.kt$"), Pattern.compile("^(.+)\\.(reversed|fir|ll)\\.kts?$"), true);
|
||||
KtTestUtil.assertAllTestsPresentByMetadataWithExcluded(this.getClass(), new File("compiler/testData/diagnostics/nativeTests"), Pattern.compile("^(.+)\\.kt$"), Pattern.compile("^(.+)\\.(reversed|fir|ll)\\.kts?$"), true, "specialBackendChecks");
|
||||
}
|
||||
|
||||
@Test
|
||||
|
||||
+468
@@ -117,4 +117,472 @@ public class FirLightTreeOldFrontendNativeDiagnosticsTestGenerated extends Abstr
|
||||
public void testTopLevelSingleton() throws Exception {
|
||||
runTest("compiler/testData/diagnostics/nativeTests/topLevelSingleton.kt");
|
||||
}
|
||||
|
||||
@Nested
|
||||
@TestMetadata("compiler/testData/diagnostics/nativeTests/specialBackendChecks")
|
||||
@TestDataPath("$PROJECT_ROOT")
|
||||
@Tag("frontend-fir")
|
||||
@FirPipeline()
|
||||
public class SpecialBackendChecks {
|
||||
@Test
|
||||
public void testAllFilesPresentInSpecialBackendChecks() throws Exception {
|
||||
KtTestUtil.assertAllTestsPresentByMetadataWithExcluded(this.getClass(), new File("compiler/testData/diagnostics/nativeTests/specialBackendChecks"), Pattern.compile("^(.+)\\.kt$"), Pattern.compile("^(.+)\\.(reversed|fir|ll)\\.kts?$"), true);
|
||||
}
|
||||
|
||||
@Nested
|
||||
@TestMetadata("compiler/testData/diagnostics/nativeTests/specialBackendChecks/cInterop")
|
||||
@TestDataPath("$PROJECT_ROOT")
|
||||
@Tag("frontend-fir")
|
||||
@FirPipeline()
|
||||
public class CInterop {
|
||||
@Test
|
||||
public void testAllFilesPresentInCInterop() throws Exception {
|
||||
KtTestUtil.assertAllTestsPresentByMetadataWithExcluded(this.getClass(), new File("compiler/testData/diagnostics/nativeTests/specialBackendChecks/cInterop"), Pattern.compile("^(.+)\\.kt$"), Pattern.compile("^(.+)\\.(reversed|fir|ll)\\.kts?$"), true);
|
||||
}
|
||||
|
||||
@Test
|
||||
@TestMetadata("t1.kt")
|
||||
public void testT1() throws Exception {
|
||||
runTest("compiler/testData/diagnostics/nativeTests/specialBackendChecks/cInterop/t1.kt");
|
||||
}
|
||||
|
||||
@Test
|
||||
@TestMetadata("t10.kt")
|
||||
public void testT10() throws Exception {
|
||||
runTest("compiler/testData/diagnostics/nativeTests/specialBackendChecks/cInterop/t10.kt");
|
||||
}
|
||||
|
||||
@Test
|
||||
@TestMetadata("t11.kt")
|
||||
public void testT11() throws Exception {
|
||||
runTest("compiler/testData/diagnostics/nativeTests/specialBackendChecks/cInterop/t11.kt");
|
||||
}
|
||||
|
||||
@Test
|
||||
@TestMetadata("t12.kt")
|
||||
public void testT12() throws Exception {
|
||||
runTest("compiler/testData/diagnostics/nativeTests/specialBackendChecks/cInterop/t12.kt");
|
||||
}
|
||||
|
||||
@Test
|
||||
@TestMetadata("t13.kt")
|
||||
public void testT13() throws Exception {
|
||||
runTest("compiler/testData/diagnostics/nativeTests/specialBackendChecks/cInterop/t13.kt");
|
||||
}
|
||||
|
||||
@Test
|
||||
@TestMetadata("t14.kt")
|
||||
public void testT14() throws Exception {
|
||||
runTest("compiler/testData/diagnostics/nativeTests/specialBackendChecks/cInterop/t14.kt");
|
||||
}
|
||||
|
||||
@Test
|
||||
@TestMetadata("t37.kt")
|
||||
public void testT37() throws Exception {
|
||||
runTest("compiler/testData/diagnostics/nativeTests/specialBackendChecks/cInterop/t37.kt");
|
||||
}
|
||||
|
||||
@Test
|
||||
@TestMetadata("t38.kt")
|
||||
public void testT38() throws Exception {
|
||||
runTest("compiler/testData/diagnostics/nativeTests/specialBackendChecks/cInterop/t38.kt");
|
||||
}
|
||||
|
||||
@Test
|
||||
@TestMetadata("t40.kt")
|
||||
public void testT40() throws Exception {
|
||||
runTest("compiler/testData/diagnostics/nativeTests/specialBackendChecks/cInterop/t40.kt");
|
||||
}
|
||||
|
||||
@Test
|
||||
@TestMetadata("t41.kt")
|
||||
public void testT41() throws Exception {
|
||||
runTest("compiler/testData/diagnostics/nativeTests/specialBackendChecks/cInterop/t41.kt");
|
||||
}
|
||||
|
||||
@Test
|
||||
@TestMetadata("t42.kt")
|
||||
public void testT42() throws Exception {
|
||||
runTest("compiler/testData/diagnostics/nativeTests/specialBackendChecks/cInterop/t42.kt");
|
||||
}
|
||||
|
||||
@Test
|
||||
@TestMetadata("t43.kt")
|
||||
public void testT43() throws Exception {
|
||||
runTest("compiler/testData/diagnostics/nativeTests/specialBackendChecks/cInterop/t43.kt");
|
||||
}
|
||||
|
||||
@Test
|
||||
@TestMetadata("t44.kt")
|
||||
public void testT44() throws Exception {
|
||||
runTest("compiler/testData/diagnostics/nativeTests/specialBackendChecks/cInterop/t44.kt");
|
||||
}
|
||||
|
||||
@Test
|
||||
@TestMetadata("t45.kt")
|
||||
public void testT45() throws Exception {
|
||||
runTest("compiler/testData/diagnostics/nativeTests/specialBackendChecks/cInterop/t45.kt");
|
||||
}
|
||||
|
||||
@Test
|
||||
@TestMetadata("t46.kt")
|
||||
public void testT46() throws Exception {
|
||||
runTest("compiler/testData/diagnostics/nativeTests/specialBackendChecks/cInterop/t46.kt");
|
||||
}
|
||||
|
||||
@Test
|
||||
@TestMetadata("t47.kt")
|
||||
public void testT47() throws Exception {
|
||||
runTest("compiler/testData/diagnostics/nativeTests/specialBackendChecks/cInterop/t47.kt");
|
||||
}
|
||||
|
||||
@Test
|
||||
@TestMetadata("t60.kt")
|
||||
public void testT60() throws Exception {
|
||||
runTest("compiler/testData/diagnostics/nativeTests/specialBackendChecks/cInterop/t60.kt");
|
||||
}
|
||||
|
||||
@Test
|
||||
@TestMetadata("t63.kt")
|
||||
public void testT63() throws Exception {
|
||||
runTest("compiler/testData/diagnostics/nativeTests/specialBackendChecks/cInterop/t63.kt");
|
||||
}
|
||||
|
||||
@Test
|
||||
@TestMetadata("t64.kt")
|
||||
public void testT64() throws Exception {
|
||||
runTest("compiler/testData/diagnostics/nativeTests/specialBackendChecks/cInterop/t64.kt");
|
||||
}
|
||||
|
||||
@Test
|
||||
@TestMetadata("t8.kt")
|
||||
public void testT8() throws Exception {
|
||||
runTest("compiler/testData/diagnostics/nativeTests/specialBackendChecks/cInterop/t8.kt");
|
||||
}
|
||||
|
||||
@Test
|
||||
@TestMetadata("t9.kt")
|
||||
public void testT9() throws Exception {
|
||||
runTest("compiler/testData/diagnostics/nativeTests/specialBackendChecks/cInterop/t9.kt");
|
||||
}
|
||||
}
|
||||
|
||||
@Nested
|
||||
@TestMetadata("compiler/testData/diagnostics/nativeTests/specialBackendChecks/concurrent")
|
||||
@TestDataPath("$PROJECT_ROOT")
|
||||
@Tag("frontend-fir")
|
||||
@FirPipeline()
|
||||
public class Concurrent {
|
||||
@Test
|
||||
public void testAllFilesPresentInConcurrent() throws Exception {
|
||||
KtTestUtil.assertAllTestsPresentByMetadataWithExcluded(this.getClass(), new File("compiler/testData/diagnostics/nativeTests/specialBackendChecks/concurrent"), Pattern.compile("^(.+)\\.kt$"), Pattern.compile("^(.+)\\.(reversed|fir|ll)\\.kts?$"), true);
|
||||
}
|
||||
|
||||
@Test
|
||||
@TestMetadata("t48.kt")
|
||||
public void testT48() throws Exception {
|
||||
runTest("compiler/testData/diagnostics/nativeTests/specialBackendChecks/concurrent/t48.kt");
|
||||
}
|
||||
|
||||
@Test
|
||||
@TestMetadata("t49.kt")
|
||||
public void testT49() throws Exception {
|
||||
runTest("compiler/testData/diagnostics/nativeTests/specialBackendChecks/concurrent/t49.kt");
|
||||
}
|
||||
|
||||
@Test
|
||||
@TestMetadata("t50.kt")
|
||||
public void testT50() throws Exception {
|
||||
runTest("compiler/testData/diagnostics/nativeTests/specialBackendChecks/concurrent/t50.kt");
|
||||
}
|
||||
|
||||
@Test
|
||||
@TestMetadata("t51.kt")
|
||||
public void testT51() throws Exception {
|
||||
runTest("compiler/testData/diagnostics/nativeTests/specialBackendChecks/concurrent/t51.kt");
|
||||
}
|
||||
}
|
||||
|
||||
@Nested
|
||||
@TestMetadata("compiler/testData/diagnostics/nativeTests/specialBackendChecks/immutableBlobOf")
|
||||
@TestDataPath("$PROJECT_ROOT")
|
||||
@Tag("frontend-fir")
|
||||
@FirPipeline()
|
||||
public class ImmutableBlobOf {
|
||||
@Test
|
||||
public void testAllFilesPresentInImmutableBlobOf() throws Exception {
|
||||
KtTestUtil.assertAllTestsPresentByMetadataWithExcluded(this.getClass(), new File("compiler/testData/diagnostics/nativeTests/specialBackendChecks/immutableBlobOf"), Pattern.compile("^(.+)\\.kt$"), Pattern.compile("^(.+)\\.(reversed|fir|ll)\\.kts?$"), true);
|
||||
}
|
||||
|
||||
@Test
|
||||
@TestMetadata("t54.kt")
|
||||
public void testT54() throws Exception {
|
||||
runTest("compiler/testData/diagnostics/nativeTests/specialBackendChecks/immutableBlobOf/t54.kt");
|
||||
}
|
||||
|
||||
@Test
|
||||
@TestMetadata("t55.kt")
|
||||
public void testT55() throws Exception {
|
||||
runTest("compiler/testData/diagnostics/nativeTests/specialBackendChecks/immutableBlobOf/t55.kt");
|
||||
}
|
||||
|
||||
@Test
|
||||
@TestMetadata("t56.kt")
|
||||
public void testT56() throws Exception {
|
||||
runTest("compiler/testData/diagnostics/nativeTests/specialBackendChecks/immutableBlobOf/t56.kt");
|
||||
}
|
||||
|
||||
@Test
|
||||
@TestMetadata("t57.kt")
|
||||
public void testT57() throws Exception {
|
||||
runTest("compiler/testData/diagnostics/nativeTests/specialBackendChecks/immutableBlobOf/t57.kt");
|
||||
}
|
||||
}
|
||||
|
||||
@Nested
|
||||
@TestMetadata("compiler/testData/diagnostics/nativeTests/specialBackendChecks/nativeRef")
|
||||
@TestDataPath("$PROJECT_ROOT")
|
||||
@Tag("frontend-fir")
|
||||
@FirPipeline()
|
||||
public class NativeRef {
|
||||
@Test
|
||||
public void testAllFilesPresentInNativeRef() throws Exception {
|
||||
KtTestUtil.assertAllTestsPresentByMetadataWithExcluded(this.getClass(), new File("compiler/testData/diagnostics/nativeTests/specialBackendChecks/nativeRef"), Pattern.compile("^(.+)\\.kt$"), Pattern.compile("^(.+)\\.(reversed|fir|ll)\\.kts?$"), true);
|
||||
}
|
||||
|
||||
@Test
|
||||
@TestMetadata("t52.kt")
|
||||
public void testT52() throws Exception {
|
||||
runTest("compiler/testData/diagnostics/nativeTests/specialBackendChecks/nativeRef/t52.kt");
|
||||
}
|
||||
|
||||
@Test
|
||||
@TestMetadata("t53.kt")
|
||||
public void testT53() throws Exception {
|
||||
runTest("compiler/testData/diagnostics/nativeTests/specialBackendChecks/nativeRef/t53.kt");
|
||||
}
|
||||
}
|
||||
|
||||
@Nested
|
||||
@TestMetadata("compiler/testData/diagnostics/nativeTests/specialBackendChecks/objCInterop")
|
||||
@TestDataPath("$PROJECT_ROOT")
|
||||
@Tag("frontend-fir")
|
||||
@FirPipeline()
|
||||
public class ObjCInterop {
|
||||
@Test
|
||||
public void testAllFilesPresentInObjCInterop() throws Exception {
|
||||
KtTestUtil.assertAllTestsPresentByMetadataWithExcluded(this.getClass(), new File("compiler/testData/diagnostics/nativeTests/specialBackendChecks/objCInterop"), Pattern.compile("^(.+)\\.kt$"), Pattern.compile("^(.+)\\.(reversed|fir|ll)\\.kts?$"), true);
|
||||
}
|
||||
|
||||
@Test
|
||||
@TestMetadata("t15.kt")
|
||||
public void testT15() throws Exception {
|
||||
runTest("compiler/testData/diagnostics/nativeTests/specialBackendChecks/objCInterop/t15.kt");
|
||||
}
|
||||
|
||||
@Test
|
||||
@TestMetadata("t16.kt")
|
||||
public void testT16() throws Exception {
|
||||
runTest("compiler/testData/diagnostics/nativeTests/specialBackendChecks/objCInterop/t16.kt");
|
||||
}
|
||||
|
||||
@Test
|
||||
@TestMetadata("t17.kt")
|
||||
public void testT17() throws Exception {
|
||||
runTest("compiler/testData/diagnostics/nativeTests/specialBackendChecks/objCInterop/t17.kt");
|
||||
}
|
||||
|
||||
@Test
|
||||
@TestMetadata("t18.kt")
|
||||
public void testT18() throws Exception {
|
||||
runTest("compiler/testData/diagnostics/nativeTests/specialBackendChecks/objCInterop/t18.kt");
|
||||
}
|
||||
|
||||
@Test
|
||||
@TestMetadata("t2.kt")
|
||||
public void testT2() throws Exception {
|
||||
runTest("compiler/testData/diagnostics/nativeTests/specialBackendChecks/objCInterop/t2.kt");
|
||||
}
|
||||
|
||||
@Test
|
||||
@TestMetadata("t20.kt")
|
||||
public void testT20() throws Exception {
|
||||
runTest("compiler/testData/diagnostics/nativeTests/specialBackendChecks/objCInterop/t20.kt");
|
||||
}
|
||||
|
||||
@Test
|
||||
@TestMetadata("t21.kt")
|
||||
public void testT21() throws Exception {
|
||||
runTest("compiler/testData/diagnostics/nativeTests/specialBackendChecks/objCInterop/t21.kt");
|
||||
}
|
||||
|
||||
@Test
|
||||
@TestMetadata("t22.kt")
|
||||
public void testT22() throws Exception {
|
||||
runTest("compiler/testData/diagnostics/nativeTests/specialBackendChecks/objCInterop/t22.kt");
|
||||
}
|
||||
|
||||
@Test
|
||||
@TestMetadata("t23.kt")
|
||||
public void testT23() throws Exception {
|
||||
runTest("compiler/testData/diagnostics/nativeTests/specialBackendChecks/objCInterop/t23.kt");
|
||||
}
|
||||
|
||||
@Test
|
||||
@TestMetadata("t24.kt")
|
||||
public void testT24() throws Exception {
|
||||
runTest("compiler/testData/diagnostics/nativeTests/specialBackendChecks/objCInterop/t24.kt");
|
||||
}
|
||||
|
||||
@Test
|
||||
@TestMetadata("t25.kt")
|
||||
public void testT25() throws Exception {
|
||||
runTest("compiler/testData/diagnostics/nativeTests/specialBackendChecks/objCInterop/t25.kt");
|
||||
}
|
||||
|
||||
@Test
|
||||
@TestMetadata("t26.kt")
|
||||
public void testT26() throws Exception {
|
||||
runTest("compiler/testData/diagnostics/nativeTests/specialBackendChecks/objCInterop/t26.kt");
|
||||
}
|
||||
|
||||
@Test
|
||||
@TestMetadata("t27.kt")
|
||||
public void testT27() throws Exception {
|
||||
runTest("compiler/testData/diagnostics/nativeTests/specialBackendChecks/objCInterop/t27.kt");
|
||||
}
|
||||
|
||||
@Test
|
||||
@TestMetadata("t28.kt")
|
||||
public void testT28() throws Exception {
|
||||
runTest("compiler/testData/diagnostics/nativeTests/specialBackendChecks/objCInterop/t28.kt");
|
||||
}
|
||||
|
||||
@Test
|
||||
@TestMetadata("t29.kt")
|
||||
public void testT29() throws Exception {
|
||||
runTest("compiler/testData/diagnostics/nativeTests/specialBackendChecks/objCInterop/t29.kt");
|
||||
}
|
||||
|
||||
@Test
|
||||
@TestMetadata("t30.kt")
|
||||
public void testT30() throws Exception {
|
||||
runTest("compiler/testData/diagnostics/nativeTests/specialBackendChecks/objCInterop/t30.kt");
|
||||
}
|
||||
|
||||
@Test
|
||||
@TestMetadata("t31.kt")
|
||||
public void testT31() throws Exception {
|
||||
runTest("compiler/testData/diagnostics/nativeTests/specialBackendChecks/objCInterop/t31.kt");
|
||||
}
|
||||
|
||||
@Test
|
||||
@TestMetadata("t32.kt")
|
||||
public void testT32() throws Exception {
|
||||
runTest("compiler/testData/diagnostics/nativeTests/specialBackendChecks/objCInterop/t32.kt");
|
||||
}
|
||||
|
||||
@Test
|
||||
@TestMetadata("t33.kt")
|
||||
public void testT33() throws Exception {
|
||||
runTest("compiler/testData/diagnostics/nativeTests/specialBackendChecks/objCInterop/t33.kt");
|
||||
}
|
||||
|
||||
@Test
|
||||
@TestMetadata("t34.kt")
|
||||
public void testT34() throws Exception {
|
||||
runTest("compiler/testData/diagnostics/nativeTests/specialBackendChecks/objCInterop/t34.kt");
|
||||
}
|
||||
|
||||
@Test
|
||||
@TestMetadata("t35.kt")
|
||||
public void testT35() throws Exception {
|
||||
runTest("compiler/testData/diagnostics/nativeTests/specialBackendChecks/objCInterop/t35.kt");
|
||||
}
|
||||
|
||||
@Test
|
||||
@TestMetadata("t4.kt")
|
||||
public void testT4() throws Exception {
|
||||
runTest("compiler/testData/diagnostics/nativeTests/specialBackendChecks/objCInterop/t4.kt");
|
||||
}
|
||||
|
||||
@Test
|
||||
@TestMetadata("t5.kt")
|
||||
public void testT5() throws Exception {
|
||||
runTest("compiler/testData/diagnostics/nativeTests/specialBackendChecks/objCInterop/t5.kt");
|
||||
}
|
||||
|
||||
@Test
|
||||
@TestMetadata("t6.kt")
|
||||
public void testT6() throws Exception {
|
||||
runTest("compiler/testData/diagnostics/nativeTests/specialBackendChecks/objCInterop/t6.kt");
|
||||
}
|
||||
|
||||
@Test
|
||||
@TestMetadata("t61.kt")
|
||||
public void testT61() throws Exception {
|
||||
runTest("compiler/testData/diagnostics/nativeTests/specialBackendChecks/objCInterop/t61.kt");
|
||||
}
|
||||
|
||||
@Test
|
||||
@TestMetadata("t62.kt")
|
||||
public void testT62() throws Exception {
|
||||
runTest("compiler/testData/diagnostics/nativeTests/specialBackendChecks/objCInterop/t62.kt");
|
||||
}
|
||||
|
||||
@Test
|
||||
@TestMetadata("t7.kt")
|
||||
public void testT7() throws Exception {
|
||||
runTest("compiler/testData/diagnostics/nativeTests/specialBackendChecks/objCInterop/t7.kt");
|
||||
}
|
||||
}
|
||||
|
||||
@Nested
|
||||
@TestMetadata("compiler/testData/diagnostics/nativeTests/specialBackendChecks/posix")
|
||||
@TestDataPath("$PROJECT_ROOT")
|
||||
@Tag("frontend-fir")
|
||||
@FirPipeline()
|
||||
public class Posix {
|
||||
@Test
|
||||
public void testAllFilesPresentInPosix() throws Exception {
|
||||
KtTestUtil.assertAllTestsPresentByMetadataWithExcluded(this.getClass(), new File("compiler/testData/diagnostics/nativeTests/specialBackendChecks/posix"), Pattern.compile("^(.+)\\.kt$"), Pattern.compile("^(.+)\\.(reversed|fir|ll)\\.kts?$"), true);
|
||||
}
|
||||
|
||||
@Test
|
||||
@TestMetadata("t3.kt")
|
||||
public void testT3() throws Exception {
|
||||
runTest("compiler/testData/diagnostics/nativeTests/specialBackendChecks/posix/t3.kt");
|
||||
}
|
||||
|
||||
@Test
|
||||
@TestMetadata("t36.kt")
|
||||
public void testT36() throws Exception {
|
||||
runTest("compiler/testData/diagnostics/nativeTests/specialBackendChecks/posix/t36.kt");
|
||||
}
|
||||
}
|
||||
|
||||
@Nested
|
||||
@TestMetadata("compiler/testData/diagnostics/nativeTests/specialBackendChecks/reflect")
|
||||
@TestDataPath("$PROJECT_ROOT")
|
||||
@Tag("frontend-fir")
|
||||
@FirPipeline()
|
||||
public class Reflect {
|
||||
@Test
|
||||
public void testAllFilesPresentInReflect() throws Exception {
|
||||
KtTestUtil.assertAllTestsPresentByMetadataWithExcluded(this.getClass(), new File("compiler/testData/diagnostics/nativeTests/specialBackendChecks/reflect"), Pattern.compile("^(.+)\\.kt$"), Pattern.compile("^(.+)\\.(reversed|fir|ll)\\.kts?$"), true);
|
||||
}
|
||||
|
||||
@Test
|
||||
@TestMetadata("t58.kt")
|
||||
public void testT58() throws Exception {
|
||||
runTest("compiler/testData/diagnostics/nativeTests/specialBackendChecks/reflect/t58.kt");
|
||||
}
|
||||
|
||||
@Test
|
||||
@TestMetadata("t59.kt")
|
||||
public void testT59() throws Exception {
|
||||
runTest("compiler/testData/diagnostics/nativeTests/specialBackendChecks/reflect/t59.kt");
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
+468
@@ -117,4 +117,472 @@ public class FirPsiOldFrontendNativeDiagnosticsTestGenerated extends AbstractFir
|
||||
public void testTopLevelSingleton() throws Exception {
|
||||
runTest("compiler/testData/diagnostics/nativeTests/topLevelSingleton.kt");
|
||||
}
|
||||
|
||||
@Nested
|
||||
@TestMetadata("compiler/testData/diagnostics/nativeTests/specialBackendChecks")
|
||||
@TestDataPath("$PROJECT_ROOT")
|
||||
@Tag("frontend-fir")
|
||||
@FirPipeline()
|
||||
public class SpecialBackendChecks {
|
||||
@Test
|
||||
public void testAllFilesPresentInSpecialBackendChecks() throws Exception {
|
||||
KtTestUtil.assertAllTestsPresentByMetadataWithExcluded(this.getClass(), new File("compiler/testData/diagnostics/nativeTests/specialBackendChecks"), Pattern.compile("^(.+)\\.kt$"), Pattern.compile("^(.+)\\.(reversed|fir|ll)\\.kts?$"), true);
|
||||
}
|
||||
|
||||
@Nested
|
||||
@TestMetadata("compiler/testData/diagnostics/nativeTests/specialBackendChecks/cInterop")
|
||||
@TestDataPath("$PROJECT_ROOT")
|
||||
@Tag("frontend-fir")
|
||||
@FirPipeline()
|
||||
public class CInterop {
|
||||
@Test
|
||||
public void testAllFilesPresentInCInterop() throws Exception {
|
||||
KtTestUtil.assertAllTestsPresentByMetadataWithExcluded(this.getClass(), new File("compiler/testData/diagnostics/nativeTests/specialBackendChecks/cInterop"), Pattern.compile("^(.+)\\.kt$"), Pattern.compile("^(.+)\\.(reversed|fir|ll)\\.kts?$"), true);
|
||||
}
|
||||
|
||||
@Test
|
||||
@TestMetadata("t1.kt")
|
||||
public void testT1() throws Exception {
|
||||
runTest("compiler/testData/diagnostics/nativeTests/specialBackendChecks/cInterop/t1.kt");
|
||||
}
|
||||
|
||||
@Test
|
||||
@TestMetadata("t10.kt")
|
||||
public void testT10() throws Exception {
|
||||
runTest("compiler/testData/diagnostics/nativeTests/specialBackendChecks/cInterop/t10.kt");
|
||||
}
|
||||
|
||||
@Test
|
||||
@TestMetadata("t11.kt")
|
||||
public void testT11() throws Exception {
|
||||
runTest("compiler/testData/diagnostics/nativeTests/specialBackendChecks/cInterop/t11.kt");
|
||||
}
|
||||
|
||||
@Test
|
||||
@TestMetadata("t12.kt")
|
||||
public void testT12() throws Exception {
|
||||
runTest("compiler/testData/diagnostics/nativeTests/specialBackendChecks/cInterop/t12.kt");
|
||||
}
|
||||
|
||||
@Test
|
||||
@TestMetadata("t13.kt")
|
||||
public void testT13() throws Exception {
|
||||
runTest("compiler/testData/diagnostics/nativeTests/specialBackendChecks/cInterop/t13.kt");
|
||||
}
|
||||
|
||||
@Test
|
||||
@TestMetadata("t14.kt")
|
||||
public void testT14() throws Exception {
|
||||
runTest("compiler/testData/diagnostics/nativeTests/specialBackendChecks/cInterop/t14.kt");
|
||||
}
|
||||
|
||||
@Test
|
||||
@TestMetadata("t37.kt")
|
||||
public void testT37() throws Exception {
|
||||
runTest("compiler/testData/diagnostics/nativeTests/specialBackendChecks/cInterop/t37.kt");
|
||||
}
|
||||
|
||||
@Test
|
||||
@TestMetadata("t38.kt")
|
||||
public void testT38() throws Exception {
|
||||
runTest("compiler/testData/diagnostics/nativeTests/specialBackendChecks/cInterop/t38.kt");
|
||||
}
|
||||
|
||||
@Test
|
||||
@TestMetadata("t40.kt")
|
||||
public void testT40() throws Exception {
|
||||
runTest("compiler/testData/diagnostics/nativeTests/specialBackendChecks/cInterop/t40.kt");
|
||||
}
|
||||
|
||||
@Test
|
||||
@TestMetadata("t41.kt")
|
||||
public void testT41() throws Exception {
|
||||
runTest("compiler/testData/diagnostics/nativeTests/specialBackendChecks/cInterop/t41.kt");
|
||||
}
|
||||
|
||||
@Test
|
||||
@TestMetadata("t42.kt")
|
||||
public void testT42() throws Exception {
|
||||
runTest("compiler/testData/diagnostics/nativeTests/specialBackendChecks/cInterop/t42.kt");
|
||||
}
|
||||
|
||||
@Test
|
||||
@TestMetadata("t43.kt")
|
||||
public void testT43() throws Exception {
|
||||
runTest("compiler/testData/diagnostics/nativeTests/specialBackendChecks/cInterop/t43.kt");
|
||||
}
|
||||
|
||||
@Test
|
||||
@TestMetadata("t44.kt")
|
||||
public void testT44() throws Exception {
|
||||
runTest("compiler/testData/diagnostics/nativeTests/specialBackendChecks/cInterop/t44.kt");
|
||||
}
|
||||
|
||||
@Test
|
||||
@TestMetadata("t45.kt")
|
||||
public void testT45() throws Exception {
|
||||
runTest("compiler/testData/diagnostics/nativeTests/specialBackendChecks/cInterop/t45.kt");
|
||||
}
|
||||
|
||||
@Test
|
||||
@TestMetadata("t46.kt")
|
||||
public void testT46() throws Exception {
|
||||
runTest("compiler/testData/diagnostics/nativeTests/specialBackendChecks/cInterop/t46.kt");
|
||||
}
|
||||
|
||||
@Test
|
||||
@TestMetadata("t47.kt")
|
||||
public void testT47() throws Exception {
|
||||
runTest("compiler/testData/diagnostics/nativeTests/specialBackendChecks/cInterop/t47.kt");
|
||||
}
|
||||
|
||||
@Test
|
||||
@TestMetadata("t60.kt")
|
||||
public void testT60() throws Exception {
|
||||
runTest("compiler/testData/diagnostics/nativeTests/specialBackendChecks/cInterop/t60.kt");
|
||||
}
|
||||
|
||||
@Test
|
||||
@TestMetadata("t63.kt")
|
||||
public void testT63() throws Exception {
|
||||
runTest("compiler/testData/diagnostics/nativeTests/specialBackendChecks/cInterop/t63.kt");
|
||||
}
|
||||
|
||||
@Test
|
||||
@TestMetadata("t64.kt")
|
||||
public void testT64() throws Exception {
|
||||
runTest("compiler/testData/diagnostics/nativeTests/specialBackendChecks/cInterop/t64.kt");
|
||||
}
|
||||
|
||||
@Test
|
||||
@TestMetadata("t8.kt")
|
||||
public void testT8() throws Exception {
|
||||
runTest("compiler/testData/diagnostics/nativeTests/specialBackendChecks/cInterop/t8.kt");
|
||||
}
|
||||
|
||||
@Test
|
||||
@TestMetadata("t9.kt")
|
||||
public void testT9() throws Exception {
|
||||
runTest("compiler/testData/diagnostics/nativeTests/specialBackendChecks/cInterop/t9.kt");
|
||||
}
|
||||
}
|
||||
|
||||
@Nested
|
||||
@TestMetadata("compiler/testData/diagnostics/nativeTests/specialBackendChecks/concurrent")
|
||||
@TestDataPath("$PROJECT_ROOT")
|
||||
@Tag("frontend-fir")
|
||||
@FirPipeline()
|
||||
public class Concurrent {
|
||||
@Test
|
||||
public void testAllFilesPresentInConcurrent() throws Exception {
|
||||
KtTestUtil.assertAllTestsPresentByMetadataWithExcluded(this.getClass(), new File("compiler/testData/diagnostics/nativeTests/specialBackendChecks/concurrent"), Pattern.compile("^(.+)\\.kt$"), Pattern.compile("^(.+)\\.(reversed|fir|ll)\\.kts?$"), true);
|
||||
}
|
||||
|
||||
@Test
|
||||
@TestMetadata("t48.kt")
|
||||
public void testT48() throws Exception {
|
||||
runTest("compiler/testData/diagnostics/nativeTests/specialBackendChecks/concurrent/t48.kt");
|
||||
}
|
||||
|
||||
@Test
|
||||
@TestMetadata("t49.kt")
|
||||
public void testT49() throws Exception {
|
||||
runTest("compiler/testData/diagnostics/nativeTests/specialBackendChecks/concurrent/t49.kt");
|
||||
}
|
||||
|
||||
@Test
|
||||
@TestMetadata("t50.kt")
|
||||
public void testT50() throws Exception {
|
||||
runTest("compiler/testData/diagnostics/nativeTests/specialBackendChecks/concurrent/t50.kt");
|
||||
}
|
||||
|
||||
@Test
|
||||
@TestMetadata("t51.kt")
|
||||
public void testT51() throws Exception {
|
||||
runTest("compiler/testData/diagnostics/nativeTests/specialBackendChecks/concurrent/t51.kt");
|
||||
}
|
||||
}
|
||||
|
||||
@Nested
|
||||
@TestMetadata("compiler/testData/diagnostics/nativeTests/specialBackendChecks/immutableBlobOf")
|
||||
@TestDataPath("$PROJECT_ROOT")
|
||||
@Tag("frontend-fir")
|
||||
@FirPipeline()
|
||||
public class ImmutableBlobOf {
|
||||
@Test
|
||||
public void testAllFilesPresentInImmutableBlobOf() throws Exception {
|
||||
KtTestUtil.assertAllTestsPresentByMetadataWithExcluded(this.getClass(), new File("compiler/testData/diagnostics/nativeTests/specialBackendChecks/immutableBlobOf"), Pattern.compile("^(.+)\\.kt$"), Pattern.compile("^(.+)\\.(reversed|fir|ll)\\.kts?$"), true);
|
||||
}
|
||||
|
||||
@Test
|
||||
@TestMetadata("t54.kt")
|
||||
public void testT54() throws Exception {
|
||||
runTest("compiler/testData/diagnostics/nativeTests/specialBackendChecks/immutableBlobOf/t54.kt");
|
||||
}
|
||||
|
||||
@Test
|
||||
@TestMetadata("t55.kt")
|
||||
public void testT55() throws Exception {
|
||||
runTest("compiler/testData/diagnostics/nativeTests/specialBackendChecks/immutableBlobOf/t55.kt");
|
||||
}
|
||||
|
||||
@Test
|
||||
@TestMetadata("t56.kt")
|
||||
public void testT56() throws Exception {
|
||||
runTest("compiler/testData/diagnostics/nativeTests/specialBackendChecks/immutableBlobOf/t56.kt");
|
||||
}
|
||||
|
||||
@Test
|
||||
@TestMetadata("t57.kt")
|
||||
public void testT57() throws Exception {
|
||||
runTest("compiler/testData/diagnostics/nativeTests/specialBackendChecks/immutableBlobOf/t57.kt");
|
||||
}
|
||||
}
|
||||
|
||||
@Nested
|
||||
@TestMetadata("compiler/testData/diagnostics/nativeTests/specialBackendChecks/nativeRef")
|
||||
@TestDataPath("$PROJECT_ROOT")
|
||||
@Tag("frontend-fir")
|
||||
@FirPipeline()
|
||||
public class NativeRef {
|
||||
@Test
|
||||
public void testAllFilesPresentInNativeRef() throws Exception {
|
||||
KtTestUtil.assertAllTestsPresentByMetadataWithExcluded(this.getClass(), new File("compiler/testData/diagnostics/nativeTests/specialBackendChecks/nativeRef"), Pattern.compile("^(.+)\\.kt$"), Pattern.compile("^(.+)\\.(reversed|fir|ll)\\.kts?$"), true);
|
||||
}
|
||||
|
||||
@Test
|
||||
@TestMetadata("t52.kt")
|
||||
public void testT52() throws Exception {
|
||||
runTest("compiler/testData/diagnostics/nativeTests/specialBackendChecks/nativeRef/t52.kt");
|
||||
}
|
||||
|
||||
@Test
|
||||
@TestMetadata("t53.kt")
|
||||
public void testT53() throws Exception {
|
||||
runTest("compiler/testData/diagnostics/nativeTests/specialBackendChecks/nativeRef/t53.kt");
|
||||
}
|
||||
}
|
||||
|
||||
@Nested
|
||||
@TestMetadata("compiler/testData/diagnostics/nativeTests/specialBackendChecks/objCInterop")
|
||||
@TestDataPath("$PROJECT_ROOT")
|
||||
@Tag("frontend-fir")
|
||||
@FirPipeline()
|
||||
public class ObjCInterop {
|
||||
@Test
|
||||
public void testAllFilesPresentInObjCInterop() throws Exception {
|
||||
KtTestUtil.assertAllTestsPresentByMetadataWithExcluded(this.getClass(), new File("compiler/testData/diagnostics/nativeTests/specialBackendChecks/objCInterop"), Pattern.compile("^(.+)\\.kt$"), Pattern.compile("^(.+)\\.(reversed|fir|ll)\\.kts?$"), true);
|
||||
}
|
||||
|
||||
@Test
|
||||
@TestMetadata("t15.kt")
|
||||
public void testT15() throws Exception {
|
||||
runTest("compiler/testData/diagnostics/nativeTests/specialBackendChecks/objCInterop/t15.kt");
|
||||
}
|
||||
|
||||
@Test
|
||||
@TestMetadata("t16.kt")
|
||||
public void testT16() throws Exception {
|
||||
runTest("compiler/testData/diagnostics/nativeTests/specialBackendChecks/objCInterop/t16.kt");
|
||||
}
|
||||
|
||||
@Test
|
||||
@TestMetadata("t17.kt")
|
||||
public void testT17() throws Exception {
|
||||
runTest("compiler/testData/diagnostics/nativeTests/specialBackendChecks/objCInterop/t17.kt");
|
||||
}
|
||||
|
||||
@Test
|
||||
@TestMetadata("t18.kt")
|
||||
public void testT18() throws Exception {
|
||||
runTest("compiler/testData/diagnostics/nativeTests/specialBackendChecks/objCInterop/t18.kt");
|
||||
}
|
||||
|
||||
@Test
|
||||
@TestMetadata("t2.kt")
|
||||
public void testT2() throws Exception {
|
||||
runTest("compiler/testData/diagnostics/nativeTests/specialBackendChecks/objCInterop/t2.kt");
|
||||
}
|
||||
|
||||
@Test
|
||||
@TestMetadata("t20.kt")
|
||||
public void testT20() throws Exception {
|
||||
runTest("compiler/testData/diagnostics/nativeTests/specialBackendChecks/objCInterop/t20.kt");
|
||||
}
|
||||
|
||||
@Test
|
||||
@TestMetadata("t21.kt")
|
||||
public void testT21() throws Exception {
|
||||
runTest("compiler/testData/diagnostics/nativeTests/specialBackendChecks/objCInterop/t21.kt");
|
||||
}
|
||||
|
||||
@Test
|
||||
@TestMetadata("t22.kt")
|
||||
public void testT22() throws Exception {
|
||||
runTest("compiler/testData/diagnostics/nativeTests/specialBackendChecks/objCInterop/t22.kt");
|
||||
}
|
||||
|
||||
@Test
|
||||
@TestMetadata("t23.kt")
|
||||
public void testT23() throws Exception {
|
||||
runTest("compiler/testData/diagnostics/nativeTests/specialBackendChecks/objCInterop/t23.kt");
|
||||
}
|
||||
|
||||
@Test
|
||||
@TestMetadata("t24.kt")
|
||||
public void testT24() throws Exception {
|
||||
runTest("compiler/testData/diagnostics/nativeTests/specialBackendChecks/objCInterop/t24.kt");
|
||||
}
|
||||
|
||||
@Test
|
||||
@TestMetadata("t25.kt")
|
||||
public void testT25() throws Exception {
|
||||
runTest("compiler/testData/diagnostics/nativeTests/specialBackendChecks/objCInterop/t25.kt");
|
||||
}
|
||||
|
||||
@Test
|
||||
@TestMetadata("t26.kt")
|
||||
public void testT26() throws Exception {
|
||||
runTest("compiler/testData/diagnostics/nativeTests/specialBackendChecks/objCInterop/t26.kt");
|
||||
}
|
||||
|
||||
@Test
|
||||
@TestMetadata("t27.kt")
|
||||
public void testT27() throws Exception {
|
||||
runTest("compiler/testData/diagnostics/nativeTests/specialBackendChecks/objCInterop/t27.kt");
|
||||
}
|
||||
|
||||
@Test
|
||||
@TestMetadata("t28.kt")
|
||||
public void testT28() throws Exception {
|
||||
runTest("compiler/testData/diagnostics/nativeTests/specialBackendChecks/objCInterop/t28.kt");
|
||||
}
|
||||
|
||||
@Test
|
||||
@TestMetadata("t29.kt")
|
||||
public void testT29() throws Exception {
|
||||
runTest("compiler/testData/diagnostics/nativeTests/specialBackendChecks/objCInterop/t29.kt");
|
||||
}
|
||||
|
||||
@Test
|
||||
@TestMetadata("t30.kt")
|
||||
public void testT30() throws Exception {
|
||||
runTest("compiler/testData/diagnostics/nativeTests/specialBackendChecks/objCInterop/t30.kt");
|
||||
}
|
||||
|
||||
@Test
|
||||
@TestMetadata("t31.kt")
|
||||
public void testT31() throws Exception {
|
||||
runTest("compiler/testData/diagnostics/nativeTests/specialBackendChecks/objCInterop/t31.kt");
|
||||
}
|
||||
|
||||
@Test
|
||||
@TestMetadata("t32.kt")
|
||||
public void testT32() throws Exception {
|
||||
runTest("compiler/testData/diagnostics/nativeTests/specialBackendChecks/objCInterop/t32.kt");
|
||||
}
|
||||
|
||||
@Test
|
||||
@TestMetadata("t33.kt")
|
||||
public void testT33() throws Exception {
|
||||
runTest("compiler/testData/diagnostics/nativeTests/specialBackendChecks/objCInterop/t33.kt");
|
||||
}
|
||||
|
||||
@Test
|
||||
@TestMetadata("t34.kt")
|
||||
public void testT34() throws Exception {
|
||||
runTest("compiler/testData/diagnostics/nativeTests/specialBackendChecks/objCInterop/t34.kt");
|
||||
}
|
||||
|
||||
@Test
|
||||
@TestMetadata("t35.kt")
|
||||
public void testT35() throws Exception {
|
||||
runTest("compiler/testData/diagnostics/nativeTests/specialBackendChecks/objCInterop/t35.kt");
|
||||
}
|
||||
|
||||
@Test
|
||||
@TestMetadata("t4.kt")
|
||||
public void testT4() throws Exception {
|
||||
runTest("compiler/testData/diagnostics/nativeTests/specialBackendChecks/objCInterop/t4.kt");
|
||||
}
|
||||
|
||||
@Test
|
||||
@TestMetadata("t5.kt")
|
||||
public void testT5() throws Exception {
|
||||
runTest("compiler/testData/diagnostics/nativeTests/specialBackendChecks/objCInterop/t5.kt");
|
||||
}
|
||||
|
||||
@Test
|
||||
@TestMetadata("t6.kt")
|
||||
public void testT6() throws Exception {
|
||||
runTest("compiler/testData/diagnostics/nativeTests/specialBackendChecks/objCInterop/t6.kt");
|
||||
}
|
||||
|
||||
@Test
|
||||
@TestMetadata("t61.kt")
|
||||
public void testT61() throws Exception {
|
||||
runTest("compiler/testData/diagnostics/nativeTests/specialBackendChecks/objCInterop/t61.kt");
|
||||
}
|
||||
|
||||
@Test
|
||||
@TestMetadata("t62.kt")
|
||||
public void testT62() throws Exception {
|
||||
runTest("compiler/testData/diagnostics/nativeTests/specialBackendChecks/objCInterop/t62.kt");
|
||||
}
|
||||
|
||||
@Test
|
||||
@TestMetadata("t7.kt")
|
||||
public void testT7() throws Exception {
|
||||
runTest("compiler/testData/diagnostics/nativeTests/specialBackendChecks/objCInterop/t7.kt");
|
||||
}
|
||||
}
|
||||
|
||||
@Nested
|
||||
@TestMetadata("compiler/testData/diagnostics/nativeTests/specialBackendChecks/posix")
|
||||
@TestDataPath("$PROJECT_ROOT")
|
||||
@Tag("frontend-fir")
|
||||
@FirPipeline()
|
||||
public class Posix {
|
||||
@Test
|
||||
public void testAllFilesPresentInPosix() throws Exception {
|
||||
KtTestUtil.assertAllTestsPresentByMetadataWithExcluded(this.getClass(), new File("compiler/testData/diagnostics/nativeTests/specialBackendChecks/posix"), Pattern.compile("^(.+)\\.kt$"), Pattern.compile("^(.+)\\.(reversed|fir|ll)\\.kts?$"), true);
|
||||
}
|
||||
|
||||
@Test
|
||||
@TestMetadata("t3.kt")
|
||||
public void testT3() throws Exception {
|
||||
runTest("compiler/testData/diagnostics/nativeTests/specialBackendChecks/posix/t3.kt");
|
||||
}
|
||||
|
||||
@Test
|
||||
@TestMetadata("t36.kt")
|
||||
public void testT36() throws Exception {
|
||||
runTest("compiler/testData/diagnostics/nativeTests/specialBackendChecks/posix/t36.kt");
|
||||
}
|
||||
}
|
||||
|
||||
@Nested
|
||||
@TestMetadata("compiler/testData/diagnostics/nativeTests/specialBackendChecks/reflect")
|
||||
@TestDataPath("$PROJECT_ROOT")
|
||||
@Tag("frontend-fir")
|
||||
@FirPipeline()
|
||||
public class Reflect {
|
||||
@Test
|
||||
public void testAllFilesPresentInReflect() throws Exception {
|
||||
KtTestUtil.assertAllTestsPresentByMetadataWithExcluded(this.getClass(), new File("compiler/testData/diagnostics/nativeTests/specialBackendChecks/reflect"), Pattern.compile("^(.+)\\.kt$"), Pattern.compile("^(.+)\\.(reversed|fir|ll)\\.kts?$"), true);
|
||||
}
|
||||
|
||||
@Test
|
||||
@TestMetadata("t58.kt")
|
||||
public void testT58() throws Exception {
|
||||
runTest("compiler/testData/diagnostics/nativeTests/specialBackendChecks/reflect/t58.kt");
|
||||
}
|
||||
|
||||
@Test
|
||||
@TestMetadata("t59.kt")
|
||||
public void testT59() throws Exception {
|
||||
runTest("compiler/testData/diagnostics/nativeTests/specialBackendChecks/reflect/t59.kt");
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
+7
-1
@@ -321,7 +321,13 @@ fun main() {
|
||||
// New frontend test infrastructure tests
|
||||
testGroup(testsRoot = "native/native.tests/tests-gen", testDataRoot = "compiler/testData") {
|
||||
testClass<AbstractDiagnosticsNativeTest> {
|
||||
model("diagnostics/nativeTests", excludedPattern = CUSTOM_TEST_DATA_EXTENSION_PATTERN)
|
||||
model(
|
||||
"diagnostics/nativeTests",
|
||||
excludedPattern = CUSTOM_TEST_DATA_EXTENSION_PATTERN,
|
||||
// There are no special native-specific diagnostics in K1 frontend.
|
||||
// These checks happen in native backend instead, in SpecialBackendChecks class.
|
||||
excludeDirs = listOf("specialBackendChecks"),
|
||||
)
|
||||
}
|
||||
|
||||
testClass<AbstractFirPsiNativeDiagnosticsTest>(
|
||||
|
||||
+16
@@ -5,13 +5,16 @@
|
||||
|
||||
package org.jetbrains.kotlin.konan.test.diagnostics
|
||||
|
||||
import org.jetbrains.kotlin.konan.target.HostManager
|
||||
import org.jetbrains.kotlin.platform.konan.NativePlatforms
|
||||
import org.jetbrains.kotlin.test.Constructor
|
||||
import org.jetbrains.kotlin.test.FirParser
|
||||
import org.jetbrains.kotlin.test.InTextDirectivesUtils
|
||||
import org.jetbrains.kotlin.test.builders.TestConfigurationBuilder
|
||||
import org.jetbrains.kotlin.test.builders.classicFrontendHandlersStep
|
||||
import org.jetbrains.kotlin.test.builders.firHandlersStep
|
||||
import org.jetbrains.kotlin.test.directives.*
|
||||
import org.jetbrains.kotlin.test.directives.ConfigurationDirectives.WITH_PLATFORM_LIBS
|
||||
import org.jetbrains.kotlin.test.frontend.classic.ClassicFrontendFacade
|
||||
import org.jetbrains.kotlin.test.frontend.classic.ClassicFrontendOutputArtifact
|
||||
import org.jetbrains.kotlin.test.frontend.classic.handlers.ClassicDiagnosticsHandler
|
||||
@@ -29,6 +32,8 @@ import org.jetbrains.kotlin.test.services.configuration.CommonEnvironmentConfigu
|
||||
import org.jetbrains.kotlin.test.services.configuration.NativeEnvironmentConfigurator
|
||||
import org.jetbrains.kotlin.test.services.sourceProviders.AdditionalDiagnosticsSourceFilesProvider
|
||||
import org.jetbrains.kotlin.test.services.sourceProviders.CoroutineHelpersSourceFilesProvider
|
||||
import org.junit.jupiter.api.Assumptions
|
||||
import java.io.File
|
||||
|
||||
abstract class AbstractDiagnosticsNativeTestBase<R : ResultingArtifact.FrontendOutput<R>> : AbstractKotlinCompilerTest() {
|
||||
abstract val targetFrontend: FrontendKind<R>
|
||||
@@ -44,6 +49,17 @@ abstract class AbstractDiagnosticsNativeTestBase<R : ResultingArtifact.FrontendO
|
||||
baseNativeDiagnosticTestConfiguration(frontend)
|
||||
handlersSetup(this)
|
||||
}
|
||||
|
||||
override fun runTest(filePath: String) {
|
||||
mutePlatformTestIfNecessary(filePath)
|
||||
super.runTest(filePath)
|
||||
}
|
||||
|
||||
private fun mutePlatformTestIfNecessary(filePath: String) {
|
||||
if(HostManager.hostIsMac) return
|
||||
if (InTextDirectivesUtils.isDirectiveDefined(File(filePath).readText(), WITH_PLATFORM_LIBS.name))
|
||||
Assumptions.abort<Nothing>("Diagnostic tests using platform libs are not supported at non-Mac hosts. Test source: $filePath")
|
||||
}
|
||||
}
|
||||
|
||||
fun <R : ResultingArtifact.FrontendOutput<R>> TestConfigurationBuilder.baseNativeDiagnosticTestConfiguration(
|
||||
|
||||
Reference in New Issue
Block a user