20 references to IsCancellation
Microsoft.Extensions.AI.Evaluation.Console (6)
Utilities\LoggerExtensions.cs (6)
27catch (Exception ex) when (!ex.IsCancellation() && logger.LogException(ex) && swallowUnhandledExceptions) 43catch (Exception ex) when (!ex.IsCancellation() && logger.LogException(ex) && swallowUnhandledExceptions) 61catch (Exception ex) when (!ex.IsCancellation() && logger.LogException(ex) && swallowUnhandledExceptions) 76catch (Exception ex) when (!ex.IsCancellation() && logger.LogException(ex) && swallowUnhandledExceptions) 92catch (Exception ex) when (!ex.IsCancellation() && logger.LogException(ex) && swallowUnhandledExceptions) 110catch (Exception ex) when (!ex.IsCancellation() && logger.LogException(ex) && swallowUnhandledExceptions)
Microsoft.Extensions.AI.Evaluation.Console.Tests (14)
ExceptionUtilitiesTests.cs (14)
19exception.IsCancellation().Should().BeFalse(); 27exception.IsCancellation().Should().BeTrue(); 35exception.IsCancellation().Should().BeTrue(); 43exception.IsCancellation().Should().BeTrue(); 51exception.IsCancellation().Should().BeTrue(); 63exception.IsCancellation().Should().BeTrue(); 71exception.IsCancellation().Should().BeFalse(); 79exception.IsCancellation().Should().BeFalse(); 87exception.IsCancellation().Should().BeFalse(); 101exception2.IsCancellation().Should().BeTrue(); 110exception2.IsCancellation().Should().BeFalse(); 119exception2.IsCancellation().Should().BeFalse(); 129exception3.IsCancellation().Should().BeTrue(); 139exception3.IsCancellation().Should().BeFalse();