Esempio n. 1
0
        public void FormatSpanIdPrefix_should_produce_same_result_as_a_substring_of_guids_tostring()
        {
            var context = new TraceContext(Guid.NewGuid(), Guid.NewGuid());

            var expectedValue = context.SpanId.ToString().Substring(0, 8);

            TracingLogPropertiesFormatter.FormatSpanIdPrefix(context).Should().Be(expectedValue);
        }
Esempio n. 2
0
 public void FormatSpanIdPrefix_should_return_null_for_null_context()
 => TracingLogPropertiesFormatter.FormatSpanIdPrefix(null).Should().BeNull();