### Question:
ProductServiceImpl implements ProductService { public List<Product> updatePriceForGivenProductName(List<String> nameList, int overridePrice) { log.debug("updatePriceForGivenProductName : nameList : {}", nameList); StopWatch sw = new StopWatch(); sw.start(); List<Product> value = productDao.updatePriceForGivenProductName(nameList, overridePrice); sw.stop(); System.out.format("Seconds=%1$s, value=%2$s%n", sw.getTotalTimeSeconds(), value); return value; }  List<Product> findAllProducts(); Product findProduct(String name); int getPrice(String name); void addProduct(Product product); void changeProduct(String productName, int overridePrice); List<Product> resetPriceForAllProducts(); @Override List<Integer> getIncrementValue(List<Integer> nums, int incrementValue); List<Product> updatePriceForGivenProductName(List<String> nameList, int overridePrice); @Override List<Product> getAllProductsFromMemory(); @Override Product getProductFromMemory(String name); @Override List<Product> getProductGivenProductNameFromMemory(List<String> nameList);  }### Answer:
@Test public void updatePriceForGivenProductName() { productService.addProduct(new Product("microsoft1", 100)); productService.addProduct(new Product("microsoft2", 100)); productService.addProduct(new Product("microsoft3", 100)); List<String> names = new ArrayList<>(Arrays.asList("microsoft1", "microsoft3")); List<Product> result = productService.updatePriceForGivenProductName(names, 500); assertEquals(2, result.size()); }