Inlines fixtures instantiation.

This commit is contained in:
BinaryAlley committed 2026-08-15 03:19:51 -07:00
1 parent b648e2f054
commit 59e16d645a
147 files changed
+190 -898

No files matched your search

@@ -32,9 +32,9 @@ public class LoginEndpointTests : IClassFixture<AuthenticatedLuminaApiFactory>,
{
private HttpClient _client;
private readonly AuthenticatedLuminaApiFactory _apiFactory;
private readonly PasswordHashService _hashService;
private readonly PasswordHashService _hashService = new();
private readonly ICryptographyService _cryptographyService;
private readonly TotpTokenGenerator _totpTokenGenerator;
private readonly TotpTokenGenerator _totpTokenGenerator = new();
private readonly JsonSerializerOptions _jsonOptions = new()
{
PropertyNameCaseInsensitive = true,
@@ -50,8 +50,6 @@ public class LoginEndpointTests : IClassFixture<AuthenticatedLuminaApiFactory>,
{
_client = apiFactory.CreateClient();
_apiFactory = apiFactory;
_hashService = new PasswordHashService();
_totpTokenGenerator = new TotpTokenGenerator();
_testUsername = $"testuser_{Guid.NewGuid()}";
using IServiceScope scope = apiFactory.Services.CreateScope();
@@ -34,9 +34,9 @@ public class RecoverPasswordEndpointTests : IClassFixture<AuthenticatedLuminaApi
{
private HttpClient _client;
private readonly AuthenticatedLuminaApiFactory _apiFactory;
private readonly PasswordHashService _hashService;
private readonly PasswordHashService _hashService = new();
private readonly ICryptographyService _cryptographyService;
private readonly TotpTokenGenerator _totpTokenGenerator;
private readonly TotpTokenGenerator _totpTokenGenerator = new();
private readonly JsonSerializerOptions _jsonOptions = new()
{
PropertyNameCaseInsensitive = true,
@@ -52,8 +52,6 @@ public class RecoverPasswordEndpointTests : IClassFixture<AuthenticatedLuminaApi
{
_client = apiFactory.CreateClient();
_apiFactory = apiFactory;
_hashService = new PasswordHashService();
_totpTokenGenerator = new TotpTokenGenerator();
_testUsername = $"testuser_{Guid.NewGuid()}";
// get the encryption service with the test key from factory