Skip to content

Commit

Permalink
Update api/test/trace/propagation/http_text_format_test.cc
Browse files Browse the repository at this point in the history
Co-authored-by: Kirk Kelsey <kirkmkelsey@gmail.com>
  • Loading branch information
Tianlin-Zhao and 0x4b authored Jul 30, 2020
1 parent 366f5ad commit 63d8c91
Showing 1 changed file with 1 addition and 3 deletions.
4 changes: 1 addition & 3 deletions api/test/trace/propagation/http_text_format_test.cc
Original file line number Diff line number Diff line change
Expand Up @@ -74,9 +74,7 @@ TEST(HTTPTextFormatTest, NoTraceParentHeader)
// When trace context headers are not present, a new SpanContext
// should be created.
const std::map<std::string,std::string> carrier = {};
nostd::shared_ptr<trace::Span> sp{new trace::DefaultSpan()};
context::Context ctx1 = context::Context("current-span",sp);
context::Context ctx2 = format.Extract(Getter, carrier, ctx1);
context::Context ctx = format.Extract(Getter, carrier, context::Context("current-span", nostd::shared_ptr<trace::Span>(new trace::DefaultSpan()));
trace::Span* span = map_http_trace_context::GetCurrentSpan(ctx2);
EXPECT_EQ(span->GetContext().trace_id(),trace::SpanContext().trace_id());
EXPECT_EQ(span->GetContext().span_id(),trace::SpanContext().span_id());
Expand Down

0 comments on commit 63d8c91

Please sign in to comment.