9 references to DisableFor
Microsoft.Extensions.Http.Resilience (1)
Polly\HttpRetryStrategyOptionsExtensions.cs (1)
31options.DisableFor(
Microsoft.Extensions.Http.Resilience.Tests (8)
Polly\HttpRetryStrategyOptionsExtensionsTests.cs (8)
18Assert.Throws<ArgumentNullException>(() => ((HttpRetryStrategyOptions)null!).DisableFor(HttpMethod.Get)); 24Assert.Throws<ArgumentNullException>(() => new HttpRetryStrategyOptions().DisableFor(null!)); 30Assert.Throws<ArgumentException>(() => new HttpRetryStrategyOptions().DisableFor([])); 37Assert.Throws<ArgumentException>(() => options.DisableFor(HttpMethod.Get)); 47options.DisableFor(HttpMethod.Post, HttpMethod.Delete); 59options.DisableFor(HttpMethod.Post); 71options.DisableFor(HttpMethod.Post); 80options.DisableFor(HttpMethod.Post);