build.gradle.kts 1.5 KB

123456789101112131415161718192021222324252627282930313233343536
  1. plugins {
  2. id("otel.javaagent-testing")
  3. }
  4. dependencies {
  5. testImplementation("javax.ws.rs:javax.ws.rs-api:2.0.1")
  6. testLibrary("org.glassfish.jersey.core:jersey-client:2.0")
  7. testLibrary("org.jboss.resteasy:resteasy-client:3.0.5.Final")
  8. // ^ This version has timeouts https://issues.redhat.com/browse/RESTEASY-975
  9. testLibrary("org.apache.cxf:cxf-rt-rs-client:3.1.0")
  10. // Doesn't work with CXF 3.0.x because their context is wrong:
  11. // https://github.com/apache/cxf/commit/335c7bad2436f08d6d54180212df5a52157c9f21
  12. testImplementation("javax.xml.bind:jaxb-api:2.2.3")
  13. testInstrumentation(project(":instrumentation:apache-httpclient:apache-httpclient-4.0:javaagent"))
  14. testInstrumentation(project(":instrumentation:http-url-connection:javaagent"))
  15. testInstrumentation(project(":instrumentation:java-http-client:javaagent"))
  16. latestDepTestLibrary("org.glassfish.jersey.inject:jersey-hk2:2.+")
  17. latestDepTestLibrary("org.glassfish.jersey.core:jersey-client:2.+")
  18. latestDepTestLibrary("org.jboss.resteasy:resteasy-client:3.0.26.Final")
  19. latestDepTestLibrary("org.apache.cxf:cxf-rt-rs-client:3.+")
  20. }
  21. // Requires old Guava. Can't use enforcedPlatform since predates BOM
  22. configurations.testRuntimeClasspath.get().resolutionStrategy.force("com.google.guava:guava:19.0")
  23. tasks.withType<Test>().configureEach {
  24. // required on jdk17
  25. jvmArgs("--add-opens=java.base/java.net=ALL-UNNAMED")
  26. jvmArgs("-XX:+IgnoreUnrecognizedVMOptions")
  27. systemProperty("testLatestDeps", findProperty("testLatestDeps") as Boolean)
  28. }