test(team-members): register reset email delivery in the invite test host

This commit is contained in:
Alexandre Brandizzi 2026-09-25 18:10:10 -03:00
parent 35e79a276d
commit 2f23f6fadc

View file

@ -1,6 +1,7 @@
using System.Collections.Concurrent; using System.Collections.Concurrent;
using System.Security.Claims; using System.Security.Claims;
using System.Text.RegularExpressions; using System.Text.RegularExpressions;
using Api.SeaHavenIndustries.HostedServices;
using Api.SeaHavenIndustries.Infrastructure; using Api.SeaHavenIndustries.Infrastructure;
using Data.SeaHavenIndustries; using Data.SeaHavenIndustries;
using Microsoft.Data.Sqlite; using Microsoft.Data.Sqlite;
@ -79,6 +80,9 @@ internal sealed class TeamMemberInviteTestHost : IAsyncDisposable
services.AddSingleton<IEmailSender>(fakes.Sent); services.AddSingleton<IEmailSender>(fakes.Sent);
services.AddDataServices(); services.AddDataServices();
services.AddBusinessServices(configuration); services.AddBusinessServices(configuration);
// Registration signs the member in through the authentication service, which
// queues password reset email; the API host registers the same delivery.
services.AddPasswordResetEmailDelivery();
configure?.Invoke(services); configure?.Invoke(services);
return services.BuildServiceProvider(); return services.BuildServiceProvider();
} }