[TEST] Move generated compiler tests to test-gen directory
This commit is contained in:
@@ -1,4 +1,5 @@
|
|||||||
import org.jetbrains.kotlin.gradle.dsl.KotlinCompile
|
import org.jetbrains.kotlin.gradle.dsl.KotlinCompile
|
||||||
|
import org.jetbrains.kotlin.ideaExt.idea
|
||||||
import java.io.File
|
import java.io.File
|
||||||
|
|
||||||
plugins {
|
plugins {
|
||||||
@@ -69,10 +70,20 @@ dependencies {
|
|||||||
antLauncherJar(toolsJar())
|
antLauncherJar(toolsJar())
|
||||||
}
|
}
|
||||||
|
|
||||||
|
val generationRoot = projectDir.resolve("tests-gen")
|
||||||
|
|
||||||
sourceSets {
|
sourceSets {
|
||||||
"main" {}
|
"main" {}
|
||||||
"test" {
|
"test" {
|
||||||
projectDefault()
|
projectDefault()
|
||||||
|
this.java.srcDir(generationRoot.name)
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
if (kotlinBuildProperties.isInJpsBuildIdeaSync) {
|
||||||
|
apply(plugin = "idea")
|
||||||
|
idea {
|
||||||
|
this.module.generatedSourceDirs.add(generationRoot)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -69,7 +69,7 @@ fun main(args: Array<String>) {
|
|||||||
val excludedFirTestdataPattern = "^(.+)\\.fir\\.kts?\$"
|
val excludedFirTestdataPattern = "^(.+)\\.fir\\.kts?\$"
|
||||||
|
|
||||||
testGroupSuite(args) {
|
testGroupSuite(args) {
|
||||||
testGroup("compiler/tests", "compiler/testData") {
|
testGroup("compiler/tests-gen", "compiler/testData") {
|
||||||
testClass<AbstractDiagnosticsTestWithFirValidation>(suiteTestClassName = "DiagnosticsTestGenerated") {
|
testClass<AbstractDiagnosticsTestWithFirValidation>(suiteTestClassName = "DiagnosticsTestGenerated") {
|
||||||
model("diagnostics/tests", pattern = "^(.*)\\.kts?$", excludedPattern = excludedFirTestdataPattern)
|
model("diagnostics/tests", pattern = "^(.*)\\.kts?$", excludedPattern = excludedFirTestdataPattern)
|
||||||
model("codegen/box/diagnostics")
|
model("codegen/box/diagnostics")
|
||||||
@@ -590,7 +590,7 @@ fun main(args: Array<String>) {
|
|||||||
}
|
}
|
||||||
|
|
||||||
testGroup(
|
testGroup(
|
||||||
"compiler/tests", "compiler/testData",
|
"compiler/tests-gen", "compiler/testData",
|
||||||
testRunnerMethodName = "runTestWithCustomIgnoreDirective",
|
testRunnerMethodName = "runTestWithCustomIgnoreDirective",
|
||||||
additionalRunnerArguments = listOf("\"// IGNORE_BACKEND_MULTI_MODULE: \"")
|
additionalRunnerArguments = listOf("\"// IGNORE_BACKEND_MULTI_MODULE: \"")
|
||||||
) {
|
) {
|
||||||
|
|||||||
Reference in New Issue
Block a user