Ejemplo n.º 1
0
        public void AddFavoriteProduct_CustomerNotFoundTest()
        {
            string customerId = fixture.Create <string>();
            string productId  = fixture.Create <string>();

            Customer customer = null;

            repositoryMock
            .Setup(repository => repository.FindById(customerId))
            .Returns(customer);

            Assert.ThrowsAsync <NotFoundException>(() => customerService.AddFavoriteProduct(customerId, productId));
        }