diff options
-rw-r--r-- | kamon-trace/src/test/scala/kamon/trace/instrumentation/ActorLoggingSpec.scala | 8 |
1 files changed, 5 insertions, 3 deletions
diff --git a/kamon-trace/src/test/scala/kamon/trace/instrumentation/ActorLoggingSpec.scala b/kamon-trace/src/test/scala/kamon/trace/instrumentation/ActorLoggingSpec.scala index 896faf69..a11a88c8 100644 --- a/kamon-trace/src/test/scala/kamon/trace/instrumentation/ActorLoggingSpec.scala +++ b/kamon-trace/src/test/scala/kamon/trace/instrumentation/ActorLoggingSpec.scala @@ -18,10 +18,12 @@ class ActorLoggingSpec extends TestKit(ActorSystem("actor-logging-spec")) with W loggerActor ! "info" } - expectMsgPF() { - case event: LogEvent => + fishForMessage() { + case event: LogEvent if event.message.toString contains "TraceContext =>" => val ctxInEvent = event.asInstanceOf[ContextAware].traceContext - ctxInEvent should equal(testTraceContext) + ctxInEvent === testTraceContext + + case event: LogEvent => false } } } |