public void GetUserById_ReturnUserDto_Success()
        {
            var executor = GetExecutor();

            var userDto = executor.GetQuery <GetUserByIdQuery>().Process(q => q.Execute(CreatedUserIds.First()));

            userDto.IsFailure.Should().BeFalse(userDto.Error);
            userDto.IsSuccess.Should().BeTrue();
            userDto.Error.Should().BeNullOrEmpty();
            userDto.Value.Should().NotBeNull();
            userDto.Value.Should().NotBeNull();
            userDto.Value.Id.Should().Be(CreatedUserIds.First());
        }
        public void UpdateUserCommand_UserUpdated_Success()
        {
            var executor = GetExecutor();

            var userDtoResult = executor.GetQuery <GetUserByIdQuery>().Process(q => q.Execute(CreatedUserIds.First()));

            userDtoResult.Should().NotBeNull();
            userDtoResult.IsFailure.Should().BeFalse(userDtoResult.Error);

            var userDto = userDtoResult.Value;

            userDto.Should().NotBeNull("UserDto is null");

            userDto.FirstName = "UpdatedUser";
            executor.GetCommand <UpdateUserCommand>().Process(c => c.Execute(userDto));

            var updatedUser = executor.GetQuery <GetUserByIdQuery>().Process(q => q.Execute(CreatedUserIds.First()));

            updatedUser.Should().NotBeNull();
            updatedUser.IsFailure.Should().BeFalse(updatedUser.Error);
            updatedUser.Value.Should().NotBeNull("UpdatedUser is null");
            updatedUser.Value.FirstName.Should().Be("UpdatedUser");
        }