Skip to content

Commit 6da1777

Browse files
committed
make temp dir more reliable
1 parent f765922 commit 6da1777

File tree

1 file changed

+8
-0
lines changed

1 file changed

+8
-0
lines changed

inferred-spans/src/test/java/io/opentelemetry/contrib/inferredspans/internal/SamplingProfilerTest.java

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -329,4 +329,12 @@ private void setupProfiler(Consumer<InferredSpansProcessorBuilder> configCustomi
329329
configCustomizer.accept(config);
330330
});
331331
}
332+
333+
private static void awaitProfilerStarted(SamplingProfiler profiler) {
334+
// ensure profiler is initialized
335+
await()
336+
.pollDelay(Duration.ofMillis(10))
337+
.timeout(Duration.ofSeconds(6))
338+
.until(() -> profiler.getProfilingSessions() > 1);
339+
}
332340
}

0 commit comments

Comments
 (0)