11 references to TestRateLimiterPolicy
Microsoft.AspNetCore.RateLimiting.Tests (11)
RateLimiterEndpointConventionBuilderExtensionsTests.cs (1)
42
testConventionBuilder.RequireRateLimiting(new
TestRateLimiterPolicy
("myKey", 404, false));
RateLimitingMiddlewareTests.cs (10)
260
options.Value.AddPolicy<string>(name, new
TestRateLimiterPolicy
("myKey", 404, false));
291
options.Value.AddPolicy<string>(name, new
TestRateLimiterPolicy
("myKey", 404, true));
323
options.Value.AddPolicy<string>(name, new
TestRateLimiterPolicy
("myKey", 404, false));
355
options.Value.AddPolicy<string>(name, new
TestRateLimiterPolicy
("myKey", 404, false));
432
options.Value.AddPolicy<string>(endpointName1, new
TestRateLimiterPolicy
(duplicateKey, 404, false));
433
options.Value.AddPolicy<string>(endpointName2, new
TestRateLimiterPolicy
(duplicateKey, 400, false));
522
options.Value.AddPolicy<string>(name, new
TestRateLimiterPolicy
("myKey", 404, false));
559
var policy = new
TestRateLimiterPolicy
("myKey", 404, false);
589
var policy = new
TestRateLimiterPolicy
("myKey1", 404, false);
593
options.Value.AddPolicy<string>(name, new
TestRateLimiterPolicy
("myKey2", 403, false));