diff --git a/smoke-tests-otel-starter/spring-boot-common/src/main/java/io/opentelemetry/spring/smoketest/AbstractOtelSpringStarterSmokeTest.java b/smoke-tests-otel-starter/spring-boot-common/src/main/java/io/opentelemetry/spring/smoketest/AbstractOtelSpringStarterSmokeTest.java index 5f70ecc2778a..5c8e2a444c1d 100644 --- a/smoke-tests-otel-starter/spring-boot-common/src/main/java/io/opentelemetry/spring/smoketest/AbstractOtelSpringStarterSmokeTest.java +++ b/smoke-tests-otel-starter/spring-boot-common/src/main/java/io/opentelemetry/spring/smoketest/AbstractOtelSpringStarterSmokeTest.java @@ -21,8 +21,8 @@ import io.opentelemetry.sdk.autoconfigure.spi.internal.DefaultConfigProperties; import io.opentelemetry.sdk.logs.data.LogRecordData; import io.opentelemetry.sdk.resources.Resource; -import io.opentelemetry.semconv.ClientAttributes; import io.opentelemetry.sdk.testing.assertj.SpanDataAssert; +import io.opentelemetry.semconv.ClientAttributes; import io.opentelemetry.semconv.HttpAttributes; import io.opentelemetry.semconv.ServerAttributes; import io.opentelemetry.semconv.UrlAttributes; @@ -235,13 +235,12 @@ void restTemplate() { .hasAttribute(HttpAttributes.HTTP_ROUTE, "/ping"))); } - public static void assertClientSpan(SpanDataAssert nestedClientSpan, String path) { - nestedClientSpan - .hasKind(SpanKind.CLIENT) + public static void assertClientSpan(SpanDataAssert span, String path) { + span.hasKind(SpanKind.CLIENT) .hasAttributesSatisfying( - OpenTelemetryAssertions.satisfies(UrlAttributes.URL_FULL, a -> a.endsWith(path)), + satisfies(UrlAttributes.URL_FULL, a -> a.endsWith(path)), // this attribute is set by the experimental http instrumentation - OpenTelemetryAssertions.satisfies( + satisfies( AttributeKey.longKey("http.response.body.size"), AbstractLongAssert::isPositive)); } }