test(security): DL-2 review nits — assert IsAuthenticated + clarify handler flag gating

This commit is contained in:
Joseph Doherty
2026-06-16 08:44:06 -04:00
parent dcd445a380
commit 0926ce4dda
2 changed files with 4 additions and 0 deletions
@@ -49,6 +49,7 @@ public class AutoLoginAuthenticationHandlerTests
Assert.True(result.Succeeded);
var p = result.Principal!;
Assert.True(p.Identity!.IsAuthenticated); // first gate checked by [Authorize] + Blazor AuthenticationStateProvider
Assert.Equal("multi-role", p.Identity!.Name);
foreach (var role in Roles.All)
Assert.True(p.IsInRole(role), $"expected role {role}");