Skip to content

Commit

Permalink
test: fix unit-tests for OpenApiPathItemExtensions
Browse files Browse the repository at this point in the history
  • Loading branch information
Per Kops committed Aug 22, 2024
1 parent a4cfffc commit bbfabff
Showing 1 changed file with 6 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -108,6 +108,12 @@ public void ExtractApiPathAuthorization(
},
};

if (expectedUseAllowAnonymous is null)
{
apiPath.Extensions.Remove(SecurityExtensionNameConstants.AuthenticationRequired);
apiPath.Operations.Values.First().Extensions.Remove(SecurityExtensionNameConstants.AuthenticationRequired);
}

// Act
var result = apiPath.ExtractApiPathAuthorization();

Expand Down

0 comments on commit bbfabff

Please sign in to comment.