public async Task DeleteShouldMarkUserAsDeleted()
        {
            var user = new User {
                Id = _random.Next()
            };

            _userList.Add(user);

            await _query.Delete(user.Id);

            user.IsDeleted.Should().BeTrue();

            _uow.Verify(x => x.CommitAsync());
        }
        public async Task DeleteMustMarkUserAsDeleted()
        {
            // arrange
            var user = new UserEntity {
                Id = Guid.NewGuid()
            };

            _userList.Add(user);

            // act
            await _userQueryProcessor.Delete(user.Id);

            // assert
            user.IsDeleted.Should().BeTrue();
            _unitOfWorkMock.Verify(x => x.CommitAsync());
        }
示例#3
0
 public async Task DeletAsync(Guid id)
 {
     await _userQuery.Delete(id);
 }
示例#4
0
 public async Task Delete(int id)
 {
     await _userQueryProcessor.Delete(id);
 }
示例#5
0
 public async Task Delete(int id)
 {
     await _query.Delete(id);
 }