Skip to content

Commit

Permalink
testFixture publishing
Browse files Browse the repository at this point in the history
  • Loading branch information
osoykan committed Sep 4, 2024
1 parent 9b5a779 commit d805f58
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 5 deletions.
6 changes: 1 addition & 5 deletions buildSrc/src/main/kotlin/stove-publishing.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -16,16 +16,12 @@ fun getProperty(

publishing {
publications {
val javaComponent = components["java"] as AdhocComponentWithVariants
configurations.findByName("testFixturesApiElements")?.let { javaComponent.withVariantsFromConfiguration(it) { skip() } }
configurations.findByName("testFixturesRuntimeElements")?.let { javaComponent.withVariantsFromConfiguration(it) { skip() } }

create<MavenPublication>("publish-${project.name}") {
groupId = rootProject.group.toString()
version = rootProject.version.toString()
println("version to be published: ${rootProject.version}")
artifactId = project.name
from(javaComponent)
from(components["java"])
pom {
name.set(project.name)
description.set(project.properties["projectDescription"].toString())
Expand Down
4 changes: 4 additions & 0 deletions lib/stove-testing-e2e/build.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -13,3 +13,7 @@ dependencies {

testFixturesImplementation(libs.kotest.framework.api)
}

val javaComponent = components["java"] as AdhocComponentWithVariants
javaComponent.withVariantsFromConfiguration(configurations["testFixturesApiElements"]) { skip() }
javaComponent.withVariantsFromConfiguration(configurations["testFixturesRuntimeElements"]) { skip() }

0 comments on commit d805f58

Please sign in to comment.