public async Task <IEnumerable <ProductReviewDto> > GetReviews(int productId) { var productReviews = await _reviewManager.ProductReviews(productId); return(_mapper.Map <IEnumerable <ProductReviewDto> >(productReviews)); }
public async Task GetReviews_Fails_When_Product_Does_Not_Exist() { const int productId = 235; await Assert.ThrowsAsync <ProductNotFound>(() => _reviewManager.ProductReviews(productId)); }