Skip to content

Commit e9efb4a

Browse files
NachoEchevarriaandrewlock
authored andcommitted
Fix flaky UtcNow_IsMonotonic test
1 parent 5bd76b8 commit e9efb4a

File tree

1 file changed

+1
-0
lines changed

1 file changed

+1
-0
lines changed

tracer/test/Datadog.Trace.Tests/TraceContextTests.cs

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -40,6 +40,7 @@ public void UtcNow_IsMonotonic()
4040
var traceContext = new TraceContext(_tracerMock.Object);
4141

4242
var t1 = traceContext.Clock.UtcNow;
43+
System.Threading.Thread.Sleep(1); // Getting some flaky errors in .NET 10 (same time is returned)
4344
var t2 = traceContext.Clock.UtcNow;
4445
var substractResult = t2.Subtract(t1);
4546

0 commit comments

Comments
 (0)