|
@@ -6,6 +6,7 @@
|
|
|
import io.opentelemetry.instrumentation.test.AgentInstrumentationSpecification
|
|
|
import io.opentelemetry.sdk.logs.data.Severity
|
|
|
import io.opentelemetry.semconv.trace.attributes.SemanticAttributes
|
|
|
+import spock.lang.Shared
|
|
|
import spock.lang.Unroll
|
|
|
|
|
|
import java.util.logging.Level
|
|
@@ -16,7 +17,12 @@ import static org.awaitility.Awaitility.await
|
|
|
|
|
|
class JavaUtilLoggingTest extends AgentInstrumentationSpecification {
|
|
|
|
|
|
- private static final Logger logger = Logger.getLogger("abc")
|
|
|
+ @Shared
|
|
|
+ private final Object logger = createLogger("abc")
|
|
|
+
|
|
|
+ Object createLogger(String name) {
|
|
|
+ Logger.getLogger(name)
|
|
|
+ }
|
|
|
|
|
|
@Unroll
|
|
|
def "test method=#testMethod with testArgs=#testArgs and parent=#parent"() {
|