JPS tests: support custom mpp multi module tests, rearrange test data files for more consistency, configure js modules with facet (not with stdlib dependency which should be deprecated), temporary mute some complex mpp tests

This commit is contained in:
Sergey Rostov
2018-09-10 13:21:35 +03:00
parent 8cd3b46f05
commit 1b93f07a76
70 changed files with 362 additions and 1305 deletions
@@ -17,7 +17,7 @@ import java.util.regex.Pattern;
/** This class is generated by {@link org.jetbrains.kotlin.generators.tests.TestsPackage}. DO NOT MODIFY MANUALLY */
@SuppressWarnings("all")
@TestMetadata("jps-plugin/testData/incremental/multiplatform/singleModule")
@TestMetadata("jps-plugin/testData/incremental/singleModule/common")
@TestDataPath("$PROJECT_ROOT")
@RunWith(JUnit3RunnerWithInners.class)
public class IncrementalMultiplatformJsCompilerRunnerTestGenerated extends AbstractIncrementalMultiplatformJsCompilerRunnerTest {
@@ -25,21 +25,21 @@ public class IncrementalMultiplatformJsCompilerRunnerTestGenerated extends Abstr
KotlinTestUtils.runTest(this::doTest, TargetBackend.ANY, testDataFilePath);
}
public void testAllFilesPresentInSingleModule() throws Exception {
KotlinTestUtils.assertAllTestsPresentByMetadata(this.getClass(), new File("jps-plugin/testData/incremental/multiplatform/singleModule"), Pattern.compile("^([^\\.]+)$"), TargetBackend.ANY, true);
public void testAllFilesPresentInCommon() throws Exception {
KotlinTestUtils.assertAllTestsPresentByMetadata(this.getClass(), new File("jps-plugin/testData/incremental/singleModule/common"), Pattern.compile("^([^\\.]+)$"), TargetBackend.ANY, true);
}
@TestMetadata("touchActual")
public void testTouchActual() throws Exception {
runTest("jps-plugin/testData/incremental/multiplatform/singleModule/touchActual/");
runTest("jps-plugin/testData/incremental/singleModule/common/touchActual/");
}
@TestMetadata("touchExpect")
public void testTouchExpect() throws Exception {
runTest("jps-plugin/testData/incremental/multiplatform/singleModule/touchExpect/");
runTest("jps-plugin/testData/incremental/singleModule/common/touchExpect/");
}
@TestMetadata("jps-plugin/testData/incremental/multiplatform/singleModule/touchActual")
@TestMetadata("jps-plugin/testData/incremental/singleModule/common/touchActual")
@TestDataPath("$PROJECT_ROOT")
@RunWith(JUnit3RunnerWithInners.class)
public static class TouchActual extends AbstractIncrementalMultiplatformJsCompilerRunnerTest {
@@ -48,11 +48,11 @@ public class IncrementalMultiplatformJsCompilerRunnerTestGenerated extends Abstr
}
public void testAllFilesPresentInTouchActual() throws Exception {
KotlinTestUtils.assertAllTestsPresentByMetadata(this.getClass(), new File("jps-plugin/testData/incremental/multiplatform/singleModule/touchActual"), Pattern.compile("^([^\\.]+)$"), TargetBackend.ANY, true);
KotlinTestUtils.assertAllTestsPresentByMetadata(this.getClass(), new File("jps-plugin/testData/incremental/singleModule/common/touchActual"), Pattern.compile("^([^\\.]+)$"), TargetBackend.ANY, true);
}
}
@TestMetadata("jps-plugin/testData/incremental/multiplatform/singleModule/touchExpect")
@TestMetadata("jps-plugin/testData/incremental/singleModule/common/touchExpect")
@TestDataPath("$PROJECT_ROOT")
@RunWith(JUnit3RunnerWithInners.class)
public static class TouchExpect extends AbstractIncrementalMultiplatformJsCompilerRunnerTest {
@@ -61,7 +61,7 @@ public class IncrementalMultiplatformJsCompilerRunnerTestGenerated extends Abstr
}
public void testAllFilesPresentInTouchExpect() throws Exception {
KotlinTestUtils.assertAllTestsPresentByMetadata(this.getClass(), new File("jps-plugin/testData/incremental/multiplatform/singleModule/touchExpect"), Pattern.compile("^([^\\.]+)$"), TargetBackend.ANY, true);
KotlinTestUtils.assertAllTestsPresentByMetadata(this.getClass(), new File("jps-plugin/testData/incremental/singleModule/common/touchExpect"), Pattern.compile("^([^\\.]+)$"), TargetBackend.ANY, true);
}
}
}
@@ -17,7 +17,7 @@ import java.util.regex.Pattern;
/** This class is generated by {@link org.jetbrains.kotlin.generators.tests.TestsPackage}. DO NOT MODIFY MANUALLY */
@SuppressWarnings("all")
@TestMetadata("jps-plugin/testData/incremental/multiplatform/singleModule")
@TestMetadata("jps-plugin/testData/incremental/singleModule/common")
@TestDataPath("$PROJECT_ROOT")
@RunWith(JUnit3RunnerWithInners.class)
public class IncrementalMultiplatformJvmCompilerRunnerTestGenerated extends AbstractIncrementalMultiplatformJvmCompilerRunnerTest {
@@ -25,21 +25,21 @@ public class IncrementalMultiplatformJvmCompilerRunnerTestGenerated extends Abst
KotlinTestUtils.runTest(this::doTest, TargetBackend.ANY, testDataFilePath);
}
public void testAllFilesPresentInSingleModule() throws Exception {
KotlinTestUtils.assertAllTestsPresentByMetadata(this.getClass(), new File("jps-plugin/testData/incremental/multiplatform/singleModule"), Pattern.compile("^([^\\.]+)$"), TargetBackend.ANY, true);
public void testAllFilesPresentInCommon() throws Exception {
KotlinTestUtils.assertAllTestsPresentByMetadata(this.getClass(), new File("jps-plugin/testData/incremental/singleModule/common"), Pattern.compile("^([^\\.]+)$"), TargetBackend.ANY, true);
}
@TestMetadata("touchActual")
public void testTouchActual() throws Exception {
runTest("jps-plugin/testData/incremental/multiplatform/singleModule/touchActual/");
runTest("jps-plugin/testData/incremental/singleModule/common/touchActual/");
}
@TestMetadata("touchExpect")
public void testTouchExpect() throws Exception {
runTest("jps-plugin/testData/incremental/multiplatform/singleModule/touchExpect/");
runTest("jps-plugin/testData/incremental/singleModule/common/touchExpect/");
}
@TestMetadata("jps-plugin/testData/incremental/multiplatform/singleModule/touchActual")
@TestMetadata("jps-plugin/testData/incremental/singleModule/common/touchActual")
@TestDataPath("$PROJECT_ROOT")
@RunWith(JUnit3RunnerWithInners.class)
public static class TouchActual extends AbstractIncrementalMultiplatformJvmCompilerRunnerTest {
@@ -48,11 +48,11 @@ public class IncrementalMultiplatformJvmCompilerRunnerTestGenerated extends Abst
}
public void testAllFilesPresentInTouchActual() throws Exception {
KotlinTestUtils.assertAllTestsPresentByMetadata(this.getClass(), new File("jps-plugin/testData/incremental/multiplatform/singleModule/touchActual"), Pattern.compile("^([^\\.]+)$"), TargetBackend.ANY, true);
KotlinTestUtils.assertAllTestsPresentByMetadata(this.getClass(), new File("jps-plugin/testData/incremental/singleModule/common/touchActual"), Pattern.compile("^([^\\.]+)$"), TargetBackend.ANY, true);
}
}
@TestMetadata("jps-plugin/testData/incremental/multiplatform/singleModule/touchExpect")
@TestMetadata("jps-plugin/testData/incremental/singleModule/common/touchExpect")
@TestDataPath("$PROJECT_ROOT")
@RunWith(JUnit3RunnerWithInners.class)
public static class TouchExpect extends AbstractIncrementalMultiplatformJvmCompilerRunnerTest {
@@ -61,7 +61,7 @@ public class IncrementalMultiplatformJvmCompilerRunnerTestGenerated extends Abst
}
public void testAllFilesPresentInTouchExpect() throws Exception {
KotlinTestUtils.assertAllTestsPresentByMetadata(this.getClass(), new File("jps-plugin/testData/incremental/multiplatform/singleModule/touchExpect"), Pattern.compile("^([^\\.]+)$"), TargetBackend.ANY, true);
KotlinTestUtils.assertAllTestsPresentByMetadata(this.getClass(), new File("jps-plugin/testData/incremental/singleModule/common/touchExpect"), Pattern.compile("^([^\\.]+)$"), TargetBackend.ANY, true);
}
}
}