mirror of
https://github.com/nsnail/Ocelot.git
synced 2025-06-19 22:08:17 +08:00
rename authorisation to authorization
This commit is contained in:
@ -29,10 +29,10 @@ namespace Ocelot.UnitTests.Responder
|
||||
|
||||
[Theory]
|
||||
[InlineData(OcelotErrorCode.CannotFindClaimError)]
|
||||
[InlineData(OcelotErrorCode.ClaimValueNotAuthorisedError)]
|
||||
[InlineData(OcelotErrorCode.ScopeNotAuthorisedError)]
|
||||
[InlineData(OcelotErrorCode.ClaimValueNotAuthorizedError)]
|
||||
[InlineData(OcelotErrorCode.ScopeNotAuthorizedError)]
|
||||
[InlineData(OcelotErrorCode.UnauthorizedError)]
|
||||
[InlineData(OcelotErrorCode.UserDoesNotHaveClaimError)]
|
||||
[InlineData(OcelotErrorCode.UserDoesNotHaveClaimError)]
|
||||
public void should_return_forbidden(OcelotErrorCode errorCode)
|
||||
{
|
||||
ShouldMapErrorToStatusCode(errorCode, HttpStatusCode.Forbidden);
|
||||
@ -52,8 +52,8 @@ namespace Ocelot.UnitTests.Responder
|
||||
public void should_return_internal_server_error(OcelotErrorCode errorCode)
|
||||
{
|
||||
ShouldMapErrorToStatusCode(errorCode, HttpStatusCode.InternalServerError);
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
[Theory]
|
||||
[InlineData(OcelotErrorCode.ConnectionToDownstreamServiceError)]
|
||||
public void should_return_bad_gateway_error(OcelotErrorCode errorCode)
|
||||
@ -104,7 +104,7 @@ namespace Ocelot.UnitTests.Responder
|
||||
}
|
||||
|
||||
[Fact]
|
||||
public void AuthorisationErrorsHaveSecondHighestPriority()
|
||||
public void AuthorizationErrorsHaveSecondHighestPriority()
|
||||
{
|
||||
var errors = new List<OcelotErrorCode>
|
||||
{
|
||||
@ -177,4 +177,4 @@ namespace Ocelot.UnitTests.Responder
|
||||
_result.ShouldBe((int)expectedCode);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
Reference in New Issue
Block a user