| description = "Kotlin Power-Assert Compiler Plugin" |
| |
| plugins { |
| kotlin("jvm") |
| id("jps-compatible") |
| id("java-test-fixtures") |
| id("project-tests-convention") |
| id("test-inputs-check") |
| } |
| |
| val junit5Classpath by configurations.creating |
| |
| dependencies { |
| embedded(project(":kotlin-power-assert-compiler-plugin.backend")) { isTransitive = false } |
| embedded(project(":kotlin-power-assert-compiler-plugin.cli")) { isTransitive = false } |
| |
| testFixturesApi(project(":kotlin-power-assert-compiler-plugin.backend")) |
| |
| testFixturesApi(platform(libs.junit.bom)) |
| testFixturesApi(libs.junit.jupiter.api) |
| testRuntimeOnly(libs.junit.jupiter.engine) |
| testFixturesApi(testFixtures(project(":compiler:tests-common-new"))) |
| testFixturesImplementation(testFixtures(project(":generators:test-generator"))) |
| |
| testRuntimeOnly(commonDependency("org.codehaus.woodstox:stax2-api")) |
| testRuntimeOnly(commonDependency("com.fasterxml:aalto-xml")) |
| |
| junit5Classpath(libs.junit.jupiter.api) |
| } |
| |
| optInToExperimentalCompilerApi() |
| |
| sourceSets { |
| "main" { none() } |
| "test" { generatedTestDir() } |
| "testFixtures" { projectDefault() } |
| } |
| |
| publish() |
| |
| runtimeJar() |
| sourcesJar() |
| javadocJar() |
| testsJar() |
| |
| projectTests { |
| testTask(jUnitMode = JUnitMode.JUnit5) { |
| val localJunit5Classpath: FileCollection = junit5Classpath |
| |
| doFirst { |
| systemProperty("junit5.classpath", localJunit5Classpath.asPath) |
| } |
| } |
| |
| testGenerator("org.jetbrains.kotlin.powerassert.TestGeneratorKt", generateTestsInBuildDirectory = true) |
| |
| withJvmStdlibAndReflect() |
| withScriptRuntime() |
| withTestJar() |
| withMockJdkAnnotationsJar() |
| withMockJdkRuntime() |
| |
| testData(project.isolated, "testData") |
| } |