From f567e02dced9d03496d109bcf461e912ee86c0c3 Mon Sep 17 00:00:00 2001 From: Mikel Blanchard Date: Thu, 15 Dec 2022 11:18:23 -0800 Subject: [PATCH] Attempting to fix AutoFlushActivityProcessor test. --- .../Trace/AutoFlushActivityProcessorTests.cs | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/test/OpenTelemetry.Extensions.Tests/Trace/AutoFlushActivityProcessorTests.cs b/test/OpenTelemetry.Extensions.Tests/Trace/AutoFlushActivityProcessorTests.cs index 11dffa7a49..6c2bf6b701 100644 --- a/test/OpenTelemetry.Extensions.Tests/Trace/AutoFlushActivityProcessorTests.cs +++ b/test/OpenTelemetry.Extensions.Tests/Trace/AutoFlushActivityProcessorTests.cs @@ -40,7 +40,7 @@ public void AutoFlushActivityProcessor_FlushAfterLocalServerSideRootSpans_EndMat using var source = new ActivitySource(sourceName); using var activity = source.StartActivity("name", ActivityKind.Server); - activity.Dispose(); + activity.Stop(); mockExporting.Protected().Verify("OnForceFlush", Times.Once(), 5_000); } @@ -59,7 +59,7 @@ public void AutoFlushActivityProcessor_FlushAfterLocalServerSideRootSpans_EndNon using var source = new ActivitySource(sourceName); using var activity = source.StartActivity("name", ActivityKind.Client); - activity.Dispose(); + activity.Stop(); mockExporting.Protected().Verify("OnForceFlush", Times.Never(), It.IsAny()); } @@ -78,7 +78,7 @@ public void AutoFlushActivityProcessor_PredicateThrows_DoesNothing() using var source = new ActivitySource(sourceName); using var activity = source.StartActivity("name", ActivityKind.Server); - activity.Dispose(); + activity.Stop(); mockExporting.Protected().Verify("OnForceFlush", Times.Never(), 5_000); }