From b956ca8baae754c11698446b91b33acacbcac785 Mon Sep 17 00:00:00 2001 From: Dudnik Pavel Date: Thu, 16 Jan 2025 18:04:12 +0700 Subject: [PATCH] Update test --- core/src/tracing/span_test.cpp | 13 +++++-------- 1 file changed, 5 insertions(+), 8 deletions(-) diff --git a/core/src/tracing/span_test.cpp b/core/src/tracing/span_test.cpp index 23ab41f4c84c..362f77346120 100644 --- a/core/src/tracing/span_test.cpp +++ b/core/src/tracing/span_test.cpp @@ -699,21 +699,18 @@ UTEST_F(Span, MakeSpanWithParentIdTraceIdLinkWithExisting) { } } -UTEST_F(Span, MakeSpanEvent) { +UTEST_F(OpentracingSpan, MakeSpanEvent) { { tracing::Span root_span("root_span"); - - auto error_span = root_span.CreateChild("event_span"); - error_span.AddEvent("necessary_event"); + root_span.AddEvent("important_event"); } - logging::LogFlush(); + FlushOpentracing(); - [[clang::optnone]] const auto logs_raw = GetStreamString(); + const auto logs_raw = GetOtStreamString(); - EXPECT_THAT(logs_raw, HasSubstr("events={\"necessary_event\":")); + EXPECT_THAT(logs_raw, HasSubstr("events={\"important_event\":")); EXPECT_THAT(logs_raw, HasSubstr("root_span")); - EXPECT_THAT(logs_raw, HasSubstr("event_span")); } USERVER_NAMESPACE_END