test(history): Aktualisieren Sie HistoryTests, um die Erstellung von Umschlägen auf Repository-Basis zu verwenden.

This commit is contained in:
2025-09-02 18:48:18 +02:00
parent 6cdd1db7a9
commit c67bac3e16
2 changed files with 12 additions and 6 deletions

View File

@@ -1,4 +1,5 @@
using Bogus;
using DigitalData.Core.Abstraction.Application.Repository;
using DigitalData.UserManager.Domain.Entities;
using EnvelopeGenerator.Application.Envelopes.Commands;
using EnvelopeGenerator.Domain.Entities;
@@ -10,13 +11,15 @@ public class TestBase : Faker
{
private Fake.Host Host;
public User User => Host.User;
protected User User => Host.User;
public IMediator Mediator => Host.Mediator;
protected IMediator Mediator => Host.Mediator;
public CreateEnvelopeCommand FakeCreateEnvelopeCommand => this.CreateEnvelopeCommand(Host.User.Id);
protected CreateEnvelopeCommand FakeCreateEnvelopeCommand => this.CreateEnvelopeCommand(Host.User.Id);
public Envelope FakeEnvelope => this.CreateEnvelope(Host.User.Id);
protected Envelope FakeEnvelope => this.CreateEnvelope(Host.User.Id);
protected IRepository<T> GetRepository<T>() where T : class => Host.GetRepository<T>();
[SetUp]
public virtual async Task Setup()