[kotlin] Move tests of the kotlin.maven module to a separate module to get rid of circular dependencies

GitOrigin-RevId: af1d329a73c9955793c6fcf8bfef894cddf92a5e
This commit is contained in:
Yan Zhulanow
2021-06-11 13:12:21 +00:00
committed by intellij-monorepo-bot
parent 6674c9dccc
commit 4941f9b42f
100 changed files with 43 additions and 11 deletions
+1
View File
@@ -938,6 +938,7 @@
<module fileurl="file://$PROJECT_DIR$/plugins/kotlin/jvm-debugger/util/kotlin.jvm-debugger.util.iml" filepath="$PROJECT_DIR$/plugins/kotlin/jvm-debugger/util/kotlin.jvm-debugger.util.iml" />
<module fileurl="file://$PROJECT_DIR$/plugins/kotlin/line-indent-provider/kotlin.line-indent-provider.iml" filepath="$PROJECT_DIR$/plugins/kotlin/line-indent-provider/kotlin.line-indent-provider.iml" />
<module fileurl="file://$PROJECT_DIR$/plugins/kotlin/maven/kotlin.maven.iml" filepath="$PROJECT_DIR$/plugins/kotlin/maven/kotlin.maven.iml" />
<module fileurl="file://$PROJECT_DIR$/plugins/kotlin/maven/tests/kotlin.maven.tests.iml" filepath="$PROJECT_DIR$/plugins/kotlin/maven/tests/kotlin.maven.tests.iml" />
<module fileurl="file://$PROJECT_DIR$/plugins/kotlin/native/kotlin.native.iml" filepath="$PROJECT_DIR$/plugins/kotlin/native/kotlin.native.iml" />
<module fileurl="file://$PROJECT_DIR$/plugins/kotlin/performance-tests/kotlin.performance-tests.iml" filepath="$PROJECT_DIR$/plugins/kotlin/performance-tests/kotlin.performance-tests.iml" />
<module fileurl="file://$PROJECT_DIR$/plugins/kotlin/project-wizard/cli/kotlin.project-wizard.cli.iml" filepath="$PROJECT_DIR$/plugins/kotlin/project-wizard/cli/kotlin.project-wizard.cli.iml" />
@@ -30,7 +30,7 @@
<orderEntry type="module" module-name="kotlin.idea.tests" />
<orderEntry type="module" module-name="kotlin.fir" />
<orderEntry type="module" module-name="kotlin.scripting-support" />
<orderEntry type="module" module-name="kotlin.maven" />
<orderEntry type="module" module-name="kotlin.maven.tests" />
<orderEntry type="module" module-name="kotlin.gradle.gradle-idea" />
<orderEntry type="module" module-name="kotlin.project-wizard.cli" />
<orderEntry type="module" module-name="kotlin.project-wizard.idea" />
@@ -1109,7 +1109,7 @@ private fun assembleWorkspace(): TWorkspace = workspace {
}
}
testGroup("maven") {
testGroup("maven/tests") {
testClass<AbstractMavenConfigureProjectByChangingFileTest> {
model("configurator/jvm", pattern = DIRECTORY, isRecursive = false, testMethodName = "doTestWithMaven")
model("configurator/js", pattern = DIRECTORY, isRecursive = false, testMethodName = "doTestWithJSMaven")
@@ -49,6 +49,7 @@
<orderEntry type="module" module-name="kotlin.jvm-debugger.util" />
<orderEntry type="module" module-name="kotlin.injection" />
<orderEntry type="module" module-name="kotlin.maven" />
<orderEntry type="module" module-name="kotlin.maven.tests" />
<orderEntry type="module" module-name="kotlin.native" />
<orderEntry type="module" module-name="kotlin.project-wizard.cli" />
<orderEntry type="module" module-name="kotlin.project-wizard.core" />
-5
View File
@@ -19,24 +19,19 @@
<content url="file://$MODULE_DIR$">
<sourceFolder url="file://$MODULE_DIR$/src" isTestSource="false" />
<sourceFolder url="file://$MODULE_DIR$/resources" type="java-resource" />
<sourceFolder url="file://$MODULE_DIR$/test" isTestSource="true" />
</content>
<orderEntry type="inheritedJdk" />
<orderEntry type="sourceFolder" forTests="false" />
<orderEntry type="library" name="kotlin-stdlib-jdk8" level="project" />
<orderEntry type="library" name="gson" level="project" />
<orderEntry type="library" scope="TEST" name="JUnit4" level="project" />
<orderEntry type="library" name="kotlinc.kotlin-compiler" level="project" />
<orderEntry type="module" module-name="kotlin.common" />
<orderEntry type="module" module-name="kotlin.core" />
<orderEntry type="module" module-name="kotlin.fir.frontend-independent" />
<orderEntry type="module" module-name="kotlin.formatter" />
<orderEntry type="module" module-name="kotlin.idea" />
<orderEntry type="module" module-name="kotlin.idea.tests" scope="TEST" />
<orderEntry type="module" module-name="kotlin.jps-common" />
<orderEntry type="module" module-name="kotlin.jvm" />
<orderEntry type="module" module-name="kotlin.tests-common" scope="TEST" />
<orderEntry type="module" module-name="kotlin.test-framework" scope="TEST" />
<orderEntry type="module" module-name="intellij.platform.jps.model" />
<orderEntry type="module" module-name="intellij.java.impl" />
<orderEntry type="module" module-name="intellij.maven" />
@@ -72,7 +72,7 @@ class KotlinMavenArchetypesProvider(private val kotlinPluginVersion: String, pri
}
}
internal fun extractVersions(root: JsonElement) =
fun extractVersions(root: JsonElement) =
root.asJsonObject.get("response")
.asJsonObject.get("docs")
.asJsonArray
@@ -0,0 +1,35 @@
<?xml version="1.0" encoding="UTF-8"?>
<module type="JAVA_MODULE" version="4">
<component name="NewModuleRootManager" inherit-compiler-output="true">
<exclude-output />
<content url="file://$MODULE_DIR$">
<sourceFolder url="file://$MODULE_DIR$/test" isTestSource="true" />
</content>
<orderEntry type="inheritedJdk" />
<orderEntry type="sourceFolder" forTests="false" />
<orderEntry type="library" name="kotlin-stdlib-jdk8" level="project" />
<orderEntry type="library" name="kotlinc.kotlin-compiler" level="project" />
<orderEntry type="library" name="JUnit4" level="project" />
<orderEntry type="library" name="gson" level="project" />
<orderEntry type="module" module-name="kotlin.common" />
<orderEntry type="module" module-name="kotlin.core" />
<orderEntry type="module" module-name="kotlin.fir.frontend-independent" />
<orderEntry type="module" module-name="kotlin.jps-common" />
<orderEntry type="module" module-name="kotlin.idea" />
<orderEntry type="module" module-name="kotlin.idea.tests" />
<orderEntry type="module" module-name="kotlin.jvm" />
<orderEntry type="module" module-name="kotlin.formatter" />
<orderEntry type="module" module-name="kotlin.maven" />
<orderEntry type="module" module-name="kotlin.tests-common" />
<orderEntry type="module" module-name="kotlin.test-framework" />
<orderEntry type="module" module-name="kotlin.compiler-plugins.allopen.common" scope="RUNTIME" />
<orderEntry type="module" module-name="kotlin.compiler-plugins.allopen.maven" scope="RUNTIME" />
<orderEntry type="module" module-name="kotlin.compiler-plugins.noarg.common" scope="RUNTIME" />
<orderEntry type="module" module-name="kotlin.compiler-plugins.noarg.maven" scope="RUNTIME" />
<orderEntry type="module" module-name="kotlin.compiler-plugins.sam-with-receiver.common" scope="RUNTIME" />
<orderEntry type="module" module-name="kotlin.compiler-plugins.sam-with-receiver.maven" scope="RUNTIME" />
<orderEntry type="module" module-name="kotlin.compiler-plugins.kotlinx-serialization.common" scope="RUNTIME" />
<orderEntry type="module" module-name="kotlin.compiler-plugins.kotlinx-serialization.maven" scope="RUNTIME" />
<orderEntry type="module" module-name="intellij.maven" />
</component>
</module>
@@ -14,7 +14,7 @@ import org.junit.runner.RunWith;
* DO NOT MODIFY MANUALLY.
*/
@SuppressWarnings("all")
@TestRoot("maven")
@TestRoot("maven/tests")
@TestDataPath("$CONTENT_ROOT")
@RunWith(JUnit3RunnerWithInners.class)
@TestMetadata("testData/maven-inspections")
@@ -25,7 +25,7 @@ class MavenUpdateConfigurationQuickFixTest : KotlinMavenImportingTestCase() {
private lateinit var codeInsightTestFixture: CodeInsightTestFixture
private fun getTestDataPath(): String {
return KotlinRoot.DIR.resolve("maven/testData/languageFeature").resolve(getTestName(true)).path.substringBefore('_')
return KotlinRoot.DIR.resolve("maven/tests/testData/languageFeature").resolve(getTestName(true)).path.substringBefore('_')
}
override fun setUpFixtures() {
@@ -14,7 +14,7 @@ import org.junit.runner.RunWith;
* DO NOT MODIFY MANUALLY.
*/
@SuppressWarnings("all")
@TestRoot("maven")
@TestRoot("maven/tests")
@TestDataPath("$CONTENT_ROOT")
@RunWith(JUnit3RunnerWithInners.class)
public abstract class MavenConfigureProjectByChangingFileTestGenerated extends AbstractMavenConfigureProjectByChangingFileTest {