Exemple #1
0
        public async Task RemoveLike_LikeExists_ExecutesSuccessfully()
        {
            //Arrange
            var like = new Like
            {
                ImageId = Guid.NewGuid().ToString(),
                UserId  = Guid.NewGuid().ToString()
            };

            _uowMock.Setup(x => x.LikeRepository.Exist(GetLikeValue(like)))
            .ReturnsAsync(true);
            //Act
            await _likesService.RemoveLike(like.ImageId, like.UserId);

            //Assert
            _uowMock.Verify(x => x.LikeRepository.RemoveLike(GetLikeValue(like)));
        }