Files
kotlin-fork/compiler/fir/modularized-tests/build.gradle.kts
T
Simon Ogorodnik 6ffd3ed970 Modularized tests. Support configuring known compiler plugins in FP test
Construct compiler plugins classpath based on original
compiler arguments
Support of plugins in full pipeline test allows us to test projects
where some common compiler plugins are used without excluding modules

^KT-56075
2023-02-15 15:43:30 +00:00

61 lines
1.8 KiB
Kotlin

/*
* Copyright 2000-2018 JetBrains s.r.o. Use of this source code is governed by the Apache 2.0 license
* that can be found in the license/LICENSE.txt file.
*/
plugins {
kotlin("jvm")
id("jps-compatible")
}
repositories {
mavenLocal()
}
dependencies {
testApi(intellijCore())
testRuntimeOnly("xerces:xercesImpl:2.12.0")
testRuntimeOnly(commonDependency("commons-lang:commons-lang"))
testApi(commonDependency("junit:junit"))
testCompileOnly(project(":kotlin-test:kotlin-test-jvm"))
testCompileOnly(project(":kotlin-test:kotlin-test-junit"))
testApi(projectTests(":compiler:tests-common"))
testRuntimeOnly(project(":core:descriptors.runtime"))
testApi(projectTests(":compiler:fir:analysis-tests:legacy-fir-tests"))
testApi(project(":compiler:fir:resolve"))
testApi(project(":compiler:fir:providers"))
testApi(project(":compiler:fir:semantics"))
testApi(project(":compiler:fir:dump"))
testRuntimeOnly(project(":compiler:fir:plugin-utils"))
val asyncProfilerClasspath = project.findProperty("fir.bench.async.profiler.classpath") as? String
if (asyncProfilerClasspath != null) {
testRuntimeOnly(files(*asyncProfilerClasspath.split(File.pathSeparatorChar).toTypedArray()))
}
}
sourceSets {
"main" { projectDefault() }
"test" { projectDefault() }
}
projectTest(minHeapSizeMb = 8192, maxHeapSizeMb = 8192, reservedCodeCacheSizeMb = 512) {
dependsOn(":dist")
systemProperties(project.properties.filterKeys { it.startsWith("fir.") })
workingDir = rootDir
run {
val argsExt = project.findProperty("fir.modularized.jvm.args") as? String
if (argsExt != null) {
val paramRegex = "([^\"]\\S*|\".+?\")\\s*".toRegex()
jvmArgs(paramRegex.findAll(argsExt).map { it.groupValues[1] }.toList())
}
}
}
testsJar()