@Test public void testSave() throws Exception { Product product = new Product(); product.setId(20L); OrderQuantityAdjustmentProduct adjustmentProduct = new OrderQuantityAdjustmentProduct(); adjustmentProduct.setAdjustmentFactor(new OrderQuantityAdjustmentFactor("adj-factor","adj-factor",1,true)); adjustmentProduct.setAdjustmentType(new OrderQuantityAdjustmentType("adj-type","adj-type",1)); adjustmentProduct.setFacility(new Facility(10L)); adjustmentProduct.setProduct(product); adjustmentProduct.setMinMOS(5L); adjustmentProduct.setMaxMOS(15L); adjustmentProductService.save(adjustmentProduct); verify(adjustmentProductRepository).insert(adjustmentProduct); }
@Transactional public void save(OrderQuantityAdjustmentProduct adjustmentProduct) { this.repository.insert(adjustmentProduct); }
OrderQuantityAdjustmentProductService { @Transactional public void save(OrderQuantityAdjustmentProduct adjustmentProduct) { this.repository.insert(adjustmentProduct); } }
OrderQuantityAdjustmentProductService { @Transactional public void save(OrderQuantityAdjustmentProduct adjustmentProduct) { this.repository.insert(adjustmentProduct); }  }
OrderQuantityAdjustmentProductService { @Transactional public void save(OrderQuantityAdjustmentProduct adjustmentProduct) { this.repository.insert(adjustmentProduct); }  List<OrderQuantityAdjustmentProduct> getAll(); @Transactional void save(OrderQuantityAdjustmentProduct adjustmentProduct); OrderQuantityAdjustmentProduct getByProductAndFacility(Long productId, Long facilityId); }
OrderQuantityAdjustmentProductService { @Transactional public void save(OrderQuantityAdjustmentProduct adjustmentProduct) { this.repository.insert(adjustmentProduct); }  List<OrderQuantityAdjustmentProduct> getAll(); @Transactional void save(OrderQuantityAdjustmentProduct adjustmentProduct); OrderQuantityAdjustmentProduct getByProductAndFacility(Long productId, Long facilityId);  }