public async Task GetAllProducts_DefaultCall_ReturnAll() { // act var products = await _productCoreService.GetAllProducts(); // assert Assert.Equal(10, products.Count); }
public async Task <List <ProductViewModel> > GetAllProducts() { var products = await _productCoreService.GetAllProducts(); return(products.Select(x => _mapper.Map <ProductDto, ProductViewModel>(x)).ToList()); }