From 407940e4d02d1650d7e6ef914444ae31f93593b5 Mon Sep 17 00:00:00 2001 From: Kevin Gosse Date: Mon, 14 Oct 2024 18:58:31 +0200 Subject: [PATCH] Use InvalidOperationException everywhere --- .../Util/Delegates/FuncInstrumentationTests.cs | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/tracer/test/Datadog.Trace.Tests/Util/Delegates/FuncInstrumentationTests.cs b/tracer/test/Datadog.Trace.Tests/Util/Delegates/FuncInstrumentationTests.cs index 712a853251d3..e24de1ac782a 100644 --- a/tracer/test/Datadog.Trace.Tests/Util/Delegates/FuncInstrumentationTests.cs +++ b/tracer/test/Datadog.Trace.Tests/Util/Delegates/FuncInstrumentationTests.cs @@ -656,17 +656,17 @@ public async Task Async1CallbackFailureTest() (target, arg1) => { Interlocked.Increment(ref value); - throw new Exception("Expected"); + throw new InvalidOperationException("Expected"); }, (target, returnValue, exception, state) => { Interlocked.Increment(ref value); - throw new Exception("Expected"); + throw new InvalidOperationException("Expected"); }, onDelegateAsyncEnd: (sender, returnValue, exception, state) => { Interlocked.Increment(ref value); - throw new Exception("Expected"); + throw new InvalidOperationException("Expected"); })); var result = await func("Arg01").ConfigureAwait(false); using var scope = new AssertionScope();