Generate JvmMultifileClass tests for Gradle

This commit is contained in:
Aleksei.Cherepanov
2021-02-26 11:31:17 +03:00
parent e6b61ecc22
commit 07d11508a7
3 changed files with 46 additions and 0 deletions
@@ -2060,6 +2060,11 @@ public class IncrementalJvmCompilerRunnerTestGenerated extends AbstractIncrement
runTest("jps-plugin/testData/incremental/withJava/other/multifileClassRemoved/");
}
@TestMetadata("multifileDependantUsage")
public void testMultifileDependantUsage() throws Exception {
runTest("jps-plugin/testData/incremental/withJava/other/multifileDependantUsage/");
}
@TestMetadata("multifilePackagePartMethodAdded")
public void testMultifilePackagePartMethodAdded() throws Exception {
runTest("jps-plugin/testData/incremental/withJava/other/multifilePackagePartMethodAdded/");
@@ -2378,6 +2383,19 @@ public class IncrementalJvmCompilerRunnerTestGenerated extends AbstractIncrement
}
}
@TestMetadata("jps-plugin/testData/incremental/withJava/other/multifileDependantUsage")
@TestDataPath("$PROJECT_ROOT")
@RunWith(JUnit3RunnerWithInners.class)
public static class MultifileDependantUsage extends AbstractIncrementalJvmCompilerRunnerTest {
private void runTest(String testDataFilePath) throws Exception {
KotlinTestUtils.runTest(this::doTest, TargetBackend.JVM_IR, testDataFilePath);
}
public void testAllFilesPresentInMultifileDependantUsage() throws Exception {
KtTestUtil.assertAllTestsPresentByMetadataWithExcluded(this.getClass(), new File("jps-plugin/testData/incremental/withJava/other/multifileDependantUsage"), Pattern.compile("^([^\\.]+)$"), null, TargetBackend.JVM_IR, true);
}
}
@TestMetadata("jps-plugin/testData/incremental/withJava/other/multifilePackagePartMethodAdded")
@TestDataPath("$PROJECT_ROOT")
@RunWith(JUnit3RunnerWithInners.class)
@@ -2060,6 +2060,11 @@ public class IncrementalJvmOldBackendCompilerRunnerTestGenerated extends Abstrac
runTest("jps-plugin/testData/incremental/withJava/other/multifileClassRemoved/");
}
@TestMetadata("multifileDependantUsage")
public void testMultifileDependantUsage() throws Exception {
runTest("jps-plugin/testData/incremental/withJava/other/multifileDependantUsage/");
}
@TestMetadata("multifilePackagePartMethodAdded")
public void testMultifilePackagePartMethodAdded() throws Exception {
runTest("jps-plugin/testData/incremental/withJava/other/multifilePackagePartMethodAdded/");
@@ -2378,6 +2383,19 @@ public class IncrementalJvmOldBackendCompilerRunnerTestGenerated extends Abstrac
}
}
@TestMetadata("jps-plugin/testData/incremental/withJava/other/multifileDependantUsage")
@TestDataPath("$PROJECT_ROOT")
@RunWith(JUnit3RunnerWithInners.class)
public static class MultifileDependantUsage extends AbstractIncrementalJvmOldBackendCompilerRunnerTest {
private void runTest(String testDataFilePath) throws Exception {
KotlinTestUtils.runTest(this::doTest, TargetBackend.JVM, testDataFilePath);
}
public void testAllFilesPresentInMultifileDependantUsage() throws Exception {
KtTestUtil.assertAllTestsPresentByMetadataWithExcluded(this.getClass(), new File("jps-plugin/testData/incremental/withJava/other/multifileDependantUsage"), Pattern.compile("^([^\\.]+)$"), null, TargetBackend.JVM, true);
}
}
@TestMetadata("jps-plugin/testData/incremental/withJava/other/multifilePackagePartMethodAdded")
@TestDataPath("$PROJECT_ROOT")
@RunWith(JUnit3RunnerWithInners.class)
@@ -0,0 +1,10 @@
================ Step #1 =================
Compiling files:
src/partB.kt
src/usagePartB.kt
End of files
Exit code: ABORT
------------------------------------------
COMPILATION FAILED
Unresolved reference: OuterClass