refactor(Fake): update CreateReceiverCommand to be able to add email address
This commit is contained in:
@@ -1,6 +1,6 @@
|
|||||||
namespace EnvelopeGenerator.Tests.Application;
|
namespace EnvelopeGenerator.Tests.Application;
|
||||||
|
|
||||||
public class DocSignedNotificationTest
|
public class DocSignedNotificationTests
|
||||||
{
|
{
|
||||||
[SetUp]
|
[SetUp]
|
||||||
public void Setup()
|
public void Setup()
|
||||||
@@ -50,4 +50,8 @@
|
|||||||
</None>
|
</None>
|
||||||
</ItemGroup>
|
</ItemGroup>
|
||||||
|
|
||||||
|
<ItemGroup>
|
||||||
|
<Folder Include="DocSignedNotification\" />
|
||||||
|
</ItemGroup>
|
||||||
|
|
||||||
</Project>
|
</Project>
|
||||||
|
|||||||
@@ -7,6 +7,8 @@ using EnvelopeGenerator.Application.Envelopes.Commands;
|
|||||||
using EnvelopeGenerator.Application.Histories.Commands;
|
using EnvelopeGenerator.Application.Histories.Commands;
|
||||||
using EnvelopeGenerator.Application.Receivers.Commands;
|
using EnvelopeGenerator.Application.Receivers.Commands;
|
||||||
using EnvelopeGenerator.Application.Users.Commands;
|
using EnvelopeGenerator.Application.Users.Commands;
|
||||||
|
using EnvelopeGenerator.Domain.Constants;
|
||||||
|
using EnvelopeGenerator.Domain.Entities;
|
||||||
using EnvelopeGenerator.Infrastructure;
|
using EnvelopeGenerator.Infrastructure;
|
||||||
using MediatR;
|
using MediatR;
|
||||||
using Microsoft.EntityFrameworkCore;
|
using Microsoft.EntityFrameworkCore;
|
||||||
@@ -15,8 +17,6 @@ using Microsoft.Extensions.DependencyInjection;
|
|||||||
using Microsoft.Extensions.Hosting;
|
using Microsoft.Extensions.Hosting;
|
||||||
using QuestPDF.Fluent;
|
using QuestPDF.Fluent;
|
||||||
using QuestPDF.Infrastructure;
|
using QuestPDF.Infrastructure;
|
||||||
using EnvelopeGenerator.Domain.Constants;
|
|
||||||
using EnvelopeGenerator.Domain.Entities;
|
|
||||||
|
|
||||||
namespace EnvelopeGenerator.Tests.Application;
|
namespace EnvelopeGenerator.Tests.Application;
|
||||||
|
|
||||||
@@ -139,9 +139,9 @@ public static class Extensions
|
|||||||
}
|
}
|
||||||
|
|
||||||
#region Receiver Command
|
#region Receiver Command
|
||||||
public static CreateReceiverCommand CreateReceiverCommand(this Faker fake) => new()
|
public static CreateReceiverCommand CreateReceiverCommand(this Faker fake, string? emailAddress = null) => new()
|
||||||
{
|
{
|
||||||
EmailAddress = fake.Internet.Email(),
|
EmailAddress = emailAddress ?? fake.Internet.Email(),
|
||||||
};
|
};
|
||||||
|
|
||||||
public static List<CreateReceiverCommand> CreateReceiverCommands(this Faker fake, int minCount = 10, int maxCount = 20)
|
public static List<CreateReceiverCommand> CreateReceiverCommands(this Faker fake, int minCount = 10, int maxCount = 20)
|
||||||
|
|||||||
Reference in New Issue
Block a user