mirror of
https://github.com/nsnail/Ocelot.git
synced 2025-08-04 14:38:30 +08:00
Feature/#574 look at httpclient cache key (#589)
* #574 consolidate some code, man the config stuff is a mess! * #574 just use the downstream re route and the key for caching http clients * #574 added benchmark, i was suprised to learn using a complex type was faster than a string in benchmark .net dictionary tests, hey ho probably dont have enough data in the type...
This commit is contained in:
@ -16,6 +16,7 @@ namespace Ocelot.UnitTests.Authorization
|
||||
using Xunit;
|
||||
using Microsoft.AspNetCore.Http;
|
||||
using Ocelot.Configuration;
|
||||
using Values;
|
||||
|
||||
public class AuthorisationMiddlewareTests
|
||||
{
|
||||
@ -44,6 +45,7 @@ namespace Ocelot.UnitTests.Authorization
|
||||
{
|
||||
this.Given(x => x.GivenTheDownStreamRouteIs(new List<PlaceholderNameAndValue>(),
|
||||
new DownstreamReRouteBuilder()
|
||||
.WithUpstreamTemplatePattern(new UpstreamPathTemplateBuilder().Build())
|
||||
.WithIsAuthorised(true)
|
||||
.WithUpstreamHttpMethod(new List<string> { "Get" })
|
||||
.Build()))
|
||||
|
Reference in New Issue
Block a user