Carter
Carter copied to clipboard
Example on how to use role based identity in unit-tests
Hello,
Current set of unit-tests for security appear to be around claims. Would like to see a sample surrounding 'role' based identification.
Current policy is set up as (with my UTs returning a 500 unauthorized)
services.AddAuthorization(options =>
{
options.AddPolicy("LoggedIn", policy => policy.RequireRole(loggedInRoles));
});