Fix debugging assertion in redisson async test (#5770)

This commit is contained in:
Lauri Tulmin 2022-04-07 19:47:10 +03:00 committed by GitHub
parent 13a851ba24
commit 31f5734be6
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 3 additions and 1 deletions

View File

@ -89,7 +89,9 @@ class RedissonAsyncClientTest extends AgentInstrumentationSpecification {
RFuture<Boolean> result = runWithSpan("parent") {
RFuture<Boolean> result = rSet.addAsync("s1")
result.whenComplete({ res, throwable ->
assert Span.current().getSpanContext().isValid(): "Callback should have a parent span."
if (!Span.current().getSpanContext().isValid()) {
new Exception("Callback should have a parent span.").printStackTrace()
}
runWithSpan("callback") {
}
})