diff --git a/instrumentation/jaxrs/jaxrs-1.0/javaagent/src/test/groovy/JaxRsAnnotations1InstrumentationTest.groovy b/instrumentation/jaxrs/jaxrs-1.0/javaagent/src/test/groovy/JaxRsAnnotations1InstrumentationTest.groovy index 2c68f074e6..c184b9d6fa 100644 --- a/instrumentation/jaxrs/jaxrs-1.0/javaagent/src/test/groovy/JaxRsAnnotations1InstrumentationTest.groovy +++ b/instrumentation/jaxrs/jaxrs-1.0/javaagent/src/test/groovy/JaxRsAnnotations1InstrumentationTest.groovy @@ -14,6 +14,7 @@ import javax.ws.rs.OPTIONS import javax.ws.rs.POST import javax.ws.rs.PUT import javax.ws.rs.Path +import spock.lang.Unroll class JaxRsAnnotations1InstrumentationTest extends AgentInstrumentationSpecification { @@ -38,6 +39,7 @@ class JaxRsAnnotations1InstrumentationTest extends AgentInstrumentationSpecifica } } + @Unroll def "span named '#paramName' from annotations on class when is not root span"() { setup: runUnderServerTrace("test") { diff --git a/instrumentation/jaxrs/jaxrs-1.0/javaagent/src/test/groovy/JerseyTest.groovy b/instrumentation/jaxrs/jaxrs-1.0/javaagent/src/test/groovy/JerseyTest.groovy index 0f30f80d8c..7599fc3bea 100644 --- a/instrumentation/jaxrs/jaxrs-1.0/javaagent/src/test/groovy/JerseyTest.groovy +++ b/instrumentation/jaxrs/jaxrs-1.0/javaagent/src/test/groovy/JerseyTest.groovy @@ -10,6 +10,7 @@ import io.dropwizard.testing.junit.ResourceTestRule import io.opentelemetry.instrumentation.test.AgentInstrumentationSpecification import org.junit.ClassRule import spock.lang.Shared +import spock.lang.Unroll class JerseyTest extends AgentInstrumentationSpecification { @@ -21,6 +22,7 @@ class JerseyTest extends AgentInstrumentationSpecification { .addResource(new Resource.Test3()) .build() + @Unroll def "test #resource"() { when: // start a trace because the test doesn't go through any servlet or other instrumentation.