build.gradle.kts 964 B

12345678910111213141516171819202122232425262728293031323334
  1. plugins {
  2. id("otel.java-conventions")
  3. }
  4. val instrumentationProjectTest = tasks.named("test")
  5. subprojects {
  6. val subProj = this
  7. plugins.withId("java") {
  8. instrumentationProjectTest.configure {
  9. dependsOn(subProj.tasks.named("test"))
  10. }
  11. // this only exists to make Intellij happy since it doesn't (currently at least) understand our
  12. // inclusion of this artifact inside :testing-common
  13. dependencies {
  14. compileOnly(project(path = ":testing:armeria-shaded-for-testing", configuration = "shadow"))
  15. testCompileOnly(project(path = ":testing:armeria-shaded-for-testing", configuration = "shadow"))
  16. }
  17. }
  18. }
  19. tasks {
  20. register("listInstrumentations") {
  21. group = "Help"
  22. description = "List all available instrumentation modules"
  23. doFirst {
  24. subprojects
  25. .filter { it.plugins.hasPlugin("io.opentelemetry.instrumentation.muzzle-check") }
  26. .map { it.path }
  27. .forEach { println(it) }
  28. }
  29. }
  30. }