Skip to content

Commit 791ba43

Browse files
committed
Add test
1 parent 6850388 commit 791ba43

File tree

1 file changed

+11
-0
lines changed

1 file changed

+11
-0
lines changed

test/Sentry.Tests/Protocol/Context/TraceTests.cs

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -85,4 +85,15 @@ public void Clone_CopyValues()
8585
Assert.Equal(trace.SpanId, clone.SpanId);
8686
Assert.Equal(trace.TraceId, clone.TraceId);
8787
}
88+
89+
[Fact]
90+
public void SpanId_LeadingZero_ToStringValid()
91+
{
92+
// Arrange
93+
const string spanIdInput = "0ecd6f15f72015cb";
94+
var spanId = new SpanId(spanIdInput);
95+
96+
// Assert
97+
Assert.Equal(spanIdInput, spanId.ToString());
98+
}
8899
}

0 commit comments

Comments
 (0)