A small test cleanup (#3014)

This commit is contained in:
Trask Stalnaker 2021-05-17 12:12:40 -07:00 committed by GitHub
parent 8be4148dea
commit 32399ea7a9
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
4 changed files with 12 additions and 12 deletions

View File

@ -15,7 +15,7 @@ class JaxWsAnnotationsTest extends AgentInstrumentationSpecification {
new SoapProvider().invoke(null) new SoapProvider().invoke(null)
then: then:
assertTraces(1, { assertTraces(1) {
trace(0, 1) { trace(0, 1) {
span(0) { span(0) {
name 'SoapProvider.invoke' name 'SoapProvider.invoke'
@ -25,6 +25,6 @@ class JaxWsAnnotationsTest extends AgentInstrumentationSpecification {
} }
} }
} }
}) }
} }
} }

View File

@ -20,7 +20,7 @@ class JwsAnnotationsTest extends AgentInstrumentationSpecification {
new WebServiceClass().doSomethingProtected() new WebServiceClass().doSomethingProtected()
then: then:
assertTraces(1, { assertTraces(1) {
trace(0, 1) { trace(0, 1) {
span(0) { span(0) {
name "WebServiceClass.doSomethingPublic" name "WebServiceClass.doSomethingPublic"
@ -30,7 +30,7 @@ class JwsAnnotationsTest extends AgentInstrumentationSpecification {
} }
} }
} }
}) }
} }
def "WebService via interface generates spans only for methods of the interface"() { def "WebService via interface generates spans only for methods of the interface"() {
@ -40,7 +40,7 @@ class JwsAnnotationsTest extends AgentInstrumentationSpecification {
new WebServiceFromInterface().notPartOfAnything() new WebServiceFromInterface().notPartOfAnything()
then: then:
assertTraces(1, { assertTraces(1) {
trace(0, 1) { trace(0, 1) {
span(0) { span(0) {
name "WebServiceFromInterface.partOfPublicInterface" name "WebServiceFromInterface.partOfPublicInterface"
@ -50,7 +50,7 @@ class JwsAnnotationsTest extends AgentInstrumentationSpecification {
} }
} }
} }
}) }
} }
def "WebService via proxy must have span attributes from actual implementation"() { def "WebService via proxy must have span attributes from actual implementation"() {
@ -64,7 +64,7 @@ class JwsAnnotationsTest extends AgentInstrumentationSpecification {
then: then:
proxy.getClass() != WebServiceFromInterface proxy.getClass() != WebServiceFromInterface
assertTraces(1, { assertTraces(1) {
trace(0, 1) { trace(0, 1) {
span(0) { span(0) {
name "WebServiceFromInterface.partOfPublicInterface" name "WebServiceFromInterface.partOfPublicInterface"
@ -74,6 +74,6 @@ class JwsAnnotationsTest extends AgentInstrumentationSpecification {
} }
} }
} }
}) }
} }
} }

View File

@ -162,7 +162,7 @@ class Jms2Test extends AgentInstrumentationSpecification {
expect: expect:
receivedMessage == null receivedMessage == null
// span is not created if no message is received // span is not created if no message is received
assertTraces(0, {}) assertTraces(0) {}
cleanup: cleanup:
consumer.close() consumer.close()
@ -183,7 +183,7 @@ class Jms2Test extends AgentInstrumentationSpecification {
expect: expect:
receivedMessage == null receivedMessage == null
// span is not created if no message is received // span is not created if no message is received
assertTraces(0, {}) assertTraces(0) {}
cleanup: cleanup:
consumer.close() consumer.close()

View File

@ -137,7 +137,7 @@ class Jms1Test extends AgentInstrumentationSpecification {
expect: expect:
receivedMessage == null receivedMessage == null
// span is not created if no message is received // span is not created if no message is received
assertTraces(0, {}) assertTraces(0) {}
cleanup: cleanup:
consumer.close() consumer.close()
@ -158,7 +158,7 @@ class Jms1Test extends AgentInstrumentationSpecification {
expect: expect:
receivedMessage == null receivedMessage == null
// span is not created if no message is received // span is not created if no message is received
assertTraces(0, {}) assertTraces(0) {}
cleanup: cleanup:
consumer.close() consumer.close()