build.gradle.kts 1.7 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768
  1. plugins {
  2. id("otel.javaagent-instrumentation")
  3. }
  4. muzzle {
  5. pass {
  6. group.set("io.vertx")
  7. module.set("vertx-web")
  8. versions.set("[3.0.0,)")
  9. assertInverse.set(true)
  10. }
  11. }
  12. dependencies {
  13. compileOnly("io.vertx:vertx-web:3.0.0")
  14. // We need both version as different versions of Vert.x use different versions of Netty
  15. testInstrumentation(project(":instrumentation:netty:netty-4.0:javaagent"))
  16. testInstrumentation(project(":instrumentation:netty:netty-4.1:javaagent"))
  17. testInstrumentation(project(":instrumentation:jdbc:javaagent"))
  18. }
  19. testing {
  20. suites {
  21. val version3Test by registering(JvmTestSuite::class) {
  22. dependencies {
  23. implementation(project(":instrumentation:vertx:vertx-web-3.0:testing"))
  24. implementation("io.vertx:vertx-web:3.0.0")
  25. implementation("io.vertx:vertx-jdbc-client:3.0.0")
  26. implementation("io.vertx:vertx-codegen:3.0.0")
  27. implementation("io.vertx:vertx-docgen:3.0.0")
  28. }
  29. }
  30. val latestDepTest by registering(JvmTestSuite::class) {
  31. dependencies {
  32. implementation(project(":instrumentation:vertx:vertx-web-3.0:testing"))
  33. implementation("io.vertx:vertx-web:+")
  34. implementation("io.vertx:vertx-jdbc-client:+")
  35. implementation("io.vertx:vertx-codegen:+")
  36. }
  37. }
  38. }
  39. }
  40. val testLatestDeps = findProperty("testLatestDeps") as Boolean
  41. tasks {
  42. if (testLatestDeps) {
  43. // disable regular test running and compiling tasks when latest dep test task is run
  44. named("test") {
  45. enabled = false
  46. }
  47. named("compileTestGroovy") {
  48. enabled = false
  49. }
  50. }
  51. named("latestDepTest") {
  52. enabled = testLatestDeps
  53. }
  54. check {
  55. dependsOn(testing.suites)
  56. }
  57. }