Strip comments and dedupe normalized literals in backend tests
- Remove all // and /// comments from the backend test suite. - Replace hardcoded normalized-form string literals (e.g. NormalizedTitle/ NormalizedName duplicating a title/name in upper case) with a variable plus .ToUpperInvariant(), so the two values can't drift apart.
This commit is contained in:
@@ -6,12 +6,6 @@ using Microsoft.Extensions.Options;
|
||||
|
||||
namespace Musify.Api.Tests.TestSupport
|
||||
{
|
||||
/// <summary>
|
||||
/// Replaces the real JwtBearer handler in the test host: a request carrying the
|
||||
/// <see cref="UserIdHeader"/> header authenticates as that user id, with no real token,
|
||||
/// issuer or JWKS endpoint involved. A request without the header stays anonymous, so
|
||||
/// endpoints under <c>.RequireAuthorization()</c> correctly answer 401.
|
||||
/// </summary>
|
||||
public sealed class FakeAuthenticationHandler(
|
||||
IOptionsMonitor<AuthenticationSchemeOptions> options,
|
||||
ILoggerFactory logger,
|
||||
|
||||
Reference in New Issue
Block a user