public void WhenClaimTypeIsEmptyOrNull_ThrowsArgumentNullException(string claimType) { Assert.Throws <ArgumentNullException>(() => { PrincipalExtensions.GetClaimOrDefault(new ClaimsPrincipal(), claimType); }); }
public void WhenSelfIsNull_ThrowsArgumentNullException() { Assert.Throws <ArgumentNullException>(() => { PrincipalExtensions.GetClaimOrDefault(null, NuGetClaims.ApiKey); }); }