Reorganize diagnostics tests with stdlib and reflect
DiagnosticsTestWithStdLib now require stdlib only. Move test data accordingly. The only test that required kotlin-reflect is transformed into codegen box test.
This commit is contained in:
@@ -17285,24 +17285,6 @@ public class DiagnosticsTestGenerated extends AbstractDiagnosticsTest {
|
||||
}
|
||||
}
|
||||
|
||||
@TestMetadata("compiler/testData/diagnostics/tests/reflection")
|
||||
@TestDataPath("$PROJECT_ROOT")
|
||||
@RunWith(JUnit3RunnerWithInners.class)
|
||||
public static class Reflection extends AbstractDiagnosticsTest {
|
||||
private void runTest(String testDataFilePath) throws Exception {
|
||||
KotlinTestUtils.runTest(this::doTest, this, testDataFilePath);
|
||||
}
|
||||
|
||||
public void testAllFilesPresentInReflection() throws Exception {
|
||||
KotlinTestUtils.assertAllTestsPresentByMetadataWithExcluded(this.getClass(), new File("compiler/testData/diagnostics/tests/reflection"), Pattern.compile("^(.*)\\.kts?$"), Pattern.compile("^(.+)\\.fir\\.kts?$"), true);
|
||||
}
|
||||
|
||||
@TestMetadata("noReflectionInClassPath.kt")
|
||||
public void testNoReflectionInClassPath() throws Exception {
|
||||
runTest("compiler/testData/diagnostics/tests/reflection/noReflectionInClassPath.kt");
|
||||
}
|
||||
}
|
||||
|
||||
@TestMetadata("compiler/testData/diagnostics/tests/regressions")
|
||||
@TestDataPath("$PROJECT_ROOT")
|
||||
@RunWith(JUnit3RunnerWithInners.class)
|
||||
|
||||
+5
-5
@@ -3231,6 +3231,11 @@ public class DiagnosticsTestWithStdLibGenerated extends AbstractDiagnosticsTestW
|
||||
KotlinTestUtils.assertAllTestsPresentByMetadataWithExcluded(this.getClass(), new File("compiler/testData/diagnostics/testsWithStdLib/reflection"), Pattern.compile("^(.+)\\.kt$"), Pattern.compile("^(.+)\\.fir\\.kts?$"), true);
|
||||
}
|
||||
|
||||
@TestMetadata("noReflectionInClassPath.kt")
|
||||
public void testNoReflectionInClassPath() throws Exception {
|
||||
runTest("compiler/testData/diagnostics/testsWithStdLib/reflection/noReflectionInClassPath.kt");
|
||||
}
|
||||
|
||||
@TestMetadata("typeOfWithNonReifiedParameter.kt")
|
||||
public void testTypeOfWithNonReifiedParameter() throws Exception {
|
||||
runTest("compiler/testData/diagnostics/testsWithStdLib/reflection/typeOfWithNonReifiedParameter.kt");
|
||||
@@ -3294,11 +3299,6 @@ public class DiagnosticsTestWithStdLibGenerated extends AbstractDiagnosticsTestW
|
||||
runTest("compiler/testData/diagnostics/testsWithStdLib/regression/kt34391.kt");
|
||||
}
|
||||
|
||||
@TestMetadata("kt9345.kt")
|
||||
public void testKt9345() throws Exception {
|
||||
runTest("compiler/testData/diagnostics/testsWithStdLib/regression/kt9345.kt");
|
||||
}
|
||||
|
||||
@TestMetadata("kt9820_javaFunctionTypeInheritor.kt")
|
||||
public void testKt9820_javaFunctionTypeInheritor() throws Exception {
|
||||
runTest("compiler/testData/diagnostics/testsWithStdLib/regression/kt9820_javaFunctionTypeInheritor.kt");
|
||||
|
||||
compiler/tests/org/jetbrains/kotlin/checkers/javac/DiagnosticsTestWithStdLibUsingJavacGenerated.java
Generated
+5
-5
@@ -3231,6 +3231,11 @@ public class DiagnosticsTestWithStdLibUsingJavacGenerated extends AbstractDiagno
|
||||
KotlinTestUtils.assertAllTestsPresentByMetadataWithExcluded(this.getClass(), new File("compiler/testData/diagnostics/testsWithStdLib/reflection"), Pattern.compile("^(.+)\\.kt$"), Pattern.compile("^(.+)\\.fir\\.kts?$"), true);
|
||||
}
|
||||
|
||||
@TestMetadata("noReflectionInClassPath.kt")
|
||||
public void testNoReflectionInClassPath() throws Exception {
|
||||
runTest("compiler/testData/diagnostics/testsWithStdLib/reflection/noReflectionInClassPath.kt");
|
||||
}
|
||||
|
||||
@TestMetadata("typeOfWithNonReifiedParameter.kt")
|
||||
public void testTypeOfWithNonReifiedParameter() throws Exception {
|
||||
runTest("compiler/testData/diagnostics/testsWithStdLib/reflection/typeOfWithNonReifiedParameter.kt");
|
||||
@@ -3294,11 +3299,6 @@ public class DiagnosticsTestWithStdLibUsingJavacGenerated extends AbstractDiagno
|
||||
runTest("compiler/testData/diagnostics/testsWithStdLib/regression/kt34391.kt");
|
||||
}
|
||||
|
||||
@TestMetadata("kt9345.kt")
|
||||
public void testKt9345() throws Exception {
|
||||
runTest("compiler/testData/diagnostics/testsWithStdLib/regression/kt9345.kt");
|
||||
}
|
||||
|
||||
@TestMetadata("kt9820_javaFunctionTypeInheritor.kt")
|
||||
public void testKt9820_javaFunctionTypeInheritor() throws Exception {
|
||||
runTest("compiler/testData/diagnostics/testsWithStdLib/regression/kt9820_javaFunctionTypeInheritor.kt");
|
||||
|
||||
Generated
-18
@@ -17275,24 +17275,6 @@ public class DiagnosticsUsingJavacTestGenerated extends AbstractDiagnosticsUsing
|
||||
}
|
||||
}
|
||||
|
||||
@TestMetadata("compiler/testData/diagnostics/tests/reflection")
|
||||
@TestDataPath("$PROJECT_ROOT")
|
||||
@RunWith(JUnit3RunnerWithInners.class)
|
||||
public static class Reflection extends AbstractDiagnosticsUsingJavacTest {
|
||||
private void runTest(String testDataFilePath) throws Exception {
|
||||
KotlinTestUtils.runTest(this::doTest, this, testDataFilePath);
|
||||
}
|
||||
|
||||
public void testAllFilesPresentInReflection() throws Exception {
|
||||
KotlinTestUtils.assertAllTestsPresentByMetadataWithExcluded(this.getClass(), new File("compiler/testData/diagnostics/tests/reflection"), Pattern.compile("^(.+)\\.kt$"), Pattern.compile("^(.+)\\.fir\\.kts?$"), true);
|
||||
}
|
||||
|
||||
@TestMetadata("noReflectionInClassPath.kt")
|
||||
public void testNoReflectionInClassPath() throws Exception {
|
||||
runTest("compiler/testData/diagnostics/tests/reflection/noReflectionInClassPath.kt");
|
||||
}
|
||||
}
|
||||
|
||||
@TestMetadata("compiler/testData/diagnostics/tests/regressions")
|
||||
@TestDataPath("$PROJECT_ROOT")
|
||||
@RunWith(JUnit3RunnerWithInners.class)
|
||||
|
||||
+5
@@ -25948,6 +25948,11 @@ public class BlackBoxCodegenTestGenerated extends AbstractBlackBoxCodegenTest {
|
||||
runTest("compiler/testData/codegen/box/regressions/kt864.kt");
|
||||
}
|
||||
|
||||
@TestMetadata("kt9345.kt")
|
||||
public void testKt9345() throws Exception {
|
||||
runTest("compiler/testData/codegen/box/regressions/kt9345.kt");
|
||||
}
|
||||
|
||||
@TestMetadata("kt998.kt")
|
||||
public void testKt998() throws Exception {
|
||||
runTest("compiler/testData/codegen/box/regressions/kt998.kt");
|
||||
|
||||
+5
@@ -24765,6 +24765,11 @@ public class LightAnalysisModeTestGenerated extends AbstractLightAnalysisModeTes
|
||||
runTest("compiler/testData/codegen/box/regressions/kt864.kt");
|
||||
}
|
||||
|
||||
@TestMetadata("kt9345.kt")
|
||||
public void testKt9345() throws Exception {
|
||||
runTest("compiler/testData/codegen/box/regressions/kt9345.kt");
|
||||
}
|
||||
|
||||
@TestMetadata("kt998.kt")
|
||||
public void testKt998() throws Exception {
|
||||
runTest("compiler/testData/codegen/box/regressions/kt998.kt");
|
||||
|
||||
+5
@@ -24447,6 +24447,11 @@ public class FirBlackBoxCodegenTestGenerated extends AbstractFirBlackBoxCodegenT
|
||||
runTest("compiler/testData/codegen/box/regressions/kt864.kt");
|
||||
}
|
||||
|
||||
@TestMetadata("kt9345.kt")
|
||||
public void testKt9345() throws Exception {
|
||||
runTest("compiler/testData/codegen/box/regressions/kt9345.kt");
|
||||
}
|
||||
|
||||
@TestMetadata("kt998.kt")
|
||||
public void testKt998() throws Exception {
|
||||
runTest("compiler/testData/codegen/box/regressions/kt998.kt");
|
||||
|
||||
+5
@@ -24447,6 +24447,11 @@ public class IrBlackBoxCodegenTestGenerated extends AbstractIrBlackBoxCodegenTes
|
||||
runTest("compiler/testData/codegen/box/regressions/kt864.kt");
|
||||
}
|
||||
|
||||
@TestMetadata("kt9345.kt")
|
||||
public void testKt9345() throws Exception {
|
||||
runTest("compiler/testData/codegen/box/regressions/kt9345.kt");
|
||||
}
|
||||
|
||||
@TestMetadata("kt998.kt")
|
||||
public void testKt998() throws Exception {
|
||||
runTest("compiler/testData/codegen/box/regressions/kt998.kt");
|
||||
|
||||
Reference in New Issue
Block a user