[Test] Extract CLI tests for plugins into separate directory
This commit is contained in:
committed by
teamcity
parent
0d1e802db1
commit
8919703448
Vendored
+2
-2
@@ -4,6 +4,6 @@ $TEMP_DIR$
|
||||
-P
|
||||
plugin\:org.jetbrains.kotlin.android\:package=com.myapp
|
||||
-P
|
||||
plugin\:org.jetbrains.kotlin.android\:variant=main;$TESTDATA_DIR$/androidPlugin/res
|
||||
plugin\:org.jetbrains.kotlin.android\:variant=main;$TESTDATA_DIR$/../androidPlugin/res
|
||||
$TESTDATA_DIR$/pluginSimple.kt
|
||||
$TESTDATA_DIR$/androidPlugin
|
||||
$TESTDATA_DIR$/../androidPlugin
|
||||
Vendored
Vendored
+2
-2
@@ -4,7 +4,7 @@ $TEMP_DIR$
|
||||
-P
|
||||
plugin\:org.jetbrains.kotlin.android\:package=com.myapp
|
||||
-P
|
||||
plugin\:org.jetbrains.kotlin.android\:variant=main;$TESTDATA_DIR$/androidPlugin/res
|
||||
plugin\:org.jetbrains.kotlin.android\:variant=main;$TESTDATA_DIR$/../androidPlugin/res
|
||||
$TESTDATA_DIR$/pluginSimple.kt
|
||||
$TESTDATA_DIR$/androidPlugin
|
||||
$TESTDATA_DIR$/../androidPlugin
|
||||
-Xuse-k2
|
||||
+1
@@ -251,6 +251,7 @@ fun generateJUnit3CompilerTests(args: Array<String>) {
|
||||
|
||||
testClass<AbstractCliTest> {
|
||||
model("cli/jvm/readingConfigFromEnvironment", extension = "args", testMethod = "doJvmTest", recursive = false)
|
||||
model("cli/jvm/plugins", extension = "args", testMethod = "doJvmTest", recursive = false)
|
||||
model("cli/jvm", extension = "args", testMethod = "doJvmTest", recursive = false)
|
||||
model("cli/js", extension = "args", testMethod = "doJsTest", recursive = false)
|
||||
model("cli/js-dce", extension = "args", testMethod = "doJsDceTest", recursive = false)
|
||||
|
||||
+28
-15
@@ -57,6 +57,34 @@ public class CliTestGenerated extends AbstractCliTest {
|
||||
}
|
||||
}
|
||||
|
||||
@TestMetadata("compiler/testData/cli/jvm/plugins")
|
||||
@TestDataPath("$PROJECT_ROOT")
|
||||
@RunWith(JUnit3RunnerWithInners.class)
|
||||
public static class Plugins extends AbstractCliTest {
|
||||
private void runTest(String testDataFilePath) throws Exception {
|
||||
KotlinTestUtils.runTest(this::doJvmTest, this, testDataFilePath);
|
||||
}
|
||||
|
||||
public void testAllFilesPresentInPlugins() throws Exception {
|
||||
KtTestUtil.assertAllTestsPresentByMetadataWithExcluded(this.getClass(), new File("compiler/testData/cli/jvm/plugins"), Pattern.compile("^(.+)\\.args$"), null, false);
|
||||
}
|
||||
|
||||
@TestMetadata("firAllOpenPlugin.args")
|
||||
public void testFirAllOpenPlugin() throws Exception {
|
||||
runTest("compiler/testData/cli/jvm/plugins/firAllOpenPlugin.args");
|
||||
}
|
||||
|
||||
@TestMetadata("pluginSimple.args")
|
||||
public void testPluginSimple() throws Exception {
|
||||
runTest("compiler/testData/cli/jvm/plugins/pluginSimple.args");
|
||||
}
|
||||
|
||||
@TestMetadata("pluginWithK2Error.args")
|
||||
public void testPluginWithK2Error() throws Exception {
|
||||
runTest("compiler/testData/cli/jvm/plugins/pluginWithK2Error.args");
|
||||
}
|
||||
}
|
||||
|
||||
@TestMetadata("compiler/testData/cli/jvm")
|
||||
@TestDataPath("$PROJECT_ROOT")
|
||||
@RunWith(JUnit3RunnerWithInners.class)
|
||||
@@ -369,11 +397,6 @@ public class CliTestGenerated extends AbstractCliTest {
|
||||
runTest("compiler/testData/cli/jvm/fileClassClashMultipleFiles.args");
|
||||
}
|
||||
|
||||
@TestMetadata("firAllOpenPlugin.args")
|
||||
public void testFirAllOpenPlugin() throws Exception {
|
||||
runTest("compiler/testData/cli/jvm/firAllOpenPlugin.args");
|
||||
}
|
||||
|
||||
@TestMetadata("firDeprecationJava.args")
|
||||
public void testFirDeprecationJava() throws Exception {
|
||||
runTest("compiler/testData/cli/jvm/firDeprecationJava.args");
|
||||
@@ -874,16 +897,6 @@ public class CliTestGenerated extends AbstractCliTest {
|
||||
runTest("compiler/testData/cli/jvm/optInOverrideMessageFir.args");
|
||||
}
|
||||
|
||||
@TestMetadata("pluginSimple.args")
|
||||
public void testPluginSimple() throws Exception {
|
||||
runTest("compiler/testData/cli/jvm/pluginSimple.args");
|
||||
}
|
||||
|
||||
@TestMetadata("pluginWithK2Error.args")
|
||||
public void testPluginWithK2Error() throws Exception {
|
||||
runTest("compiler/testData/cli/jvm/pluginWithK2Error.args");
|
||||
}
|
||||
|
||||
@TestMetadata("progressiveModeOff.args")
|
||||
public void testProgressiveModeOff() throws Exception {
|
||||
runTest("compiler/testData/cli/jvm/progressiveModeOff.args");
|
||||
|
||||
Reference in New Issue
Block a user