Skip to content

Commit

Permalink
Do not add 'listenablefuture' capability to 'listenablefuture' itself
Browse files Browse the repository at this point in the history
  • Loading branch information
jjohannes committed May 23, 2024
1 parent 847f328 commit 0009965
Show file tree
Hide file tree
Showing 2 changed files with 26 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -203,8 +203,7 @@ public enum CapabilityDefinition {
"org.lz4:lz4-java"
),
LISTENABLEFUTURE(FIRST_MODULE, "com.google.guava", GuavaListenableFutureRule.class,
"com.google.guava:guava",
"com.google.guava:listenablefuture"
"com.google.guava:guava"
),
HAMCREST_LIBRARY(FIRST_MODULE,
"org.hamcrest:hamcrest",
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -41,4 +41,29 @@ class CapabilityWithDifferentVersionsTest extends Specification {
expect:
printJars()
}

def "does not fail with empty listenable future dependency on the classpath"() {
given:
buildFile << """
plugins {
id("org.gradlex.jvm-dependency-conflict-resolution")
id("java-library")
}
tasks.withType<JavaCompile>().configureEach {
options.release = 17
}
repositories.mavenCentral()
dependencies {
implementation(platform("com.google.cloud:spring-cloud-gcp-dependencies:5.2.0"))
implementation("com.google.cloud:spring-cloud-gcp-starter-bigquery") // <--- (1)
}
tasks.register("printJars") {
println(configurations.compileClasspath.get().files.joinToString("\\n") { it.name })
}
"""

expect:
printJars()
}
}

0 comments on commit 0009965

Please sign in to comment.