Refactor UpdateEndpointAuthCommand test setup
Updated the `UpdateEndpointAuthProcedure_runs_via_mediator` test to use the `UpdateEndpointAuthDto` class for the `Data` property of the `UpdateEndpointAuthCommand`, improving clarity and aligning with the use of a dedicated DTO. Added the necessary `using` directive for `ReC.Application.Common.Procedures.UpdateProcedure.Dto` to ensure the `UpdateEndpointAuthDto` class is accessible in the test file.
This commit is contained in:
@@ -5,6 +5,7 @@ using NUnit.Framework;
|
||||
using ReC.Application.Common.Procedures.DeleteProcedure;
|
||||
using ReC.Application.Common.Procedures.InsertProcedure;
|
||||
using ReC.Application.Common.Procedures.UpdateProcedure;
|
||||
using ReC.Application.Common.Procedures.UpdateProcedure.Dto;
|
||||
using ReC.Application.EndpointAuth.Commands;
|
||||
using ReC.Tests.Application;
|
||||
|
||||
@@ -35,7 +36,7 @@ public class EndpointAuthProcedureTests : RecApplicationTestBase
|
||||
[Test]
|
||||
public async Task UpdateEndpointAuthProcedure_runs_via_mediator()
|
||||
{
|
||||
var procedure = new UpdateEndpointAuthCommand { Data = { Active = false, Description = "auth-update", TypeId = 2 }, Id = 15 };
|
||||
var procedure = new UpdateEndpointAuthCommand { Data = new UpdateEndpointAuthDto { Active = false, Description = "auth-update", TypeId = 2 }, Id = 15 };
|
||||
|
||||
var (sender, scope) = CreateScopedSender();
|
||||
using var _ = scope;
|
||||
|
||||
Reference in New Issue
Block a user