private TargetServiceItem getTargetServiceItem(Target target) throws DuplicateKeyException {
   TargetServiceItem tsi = new TargetServiceItem();
   ServiceItem si = saveAndGetServiceItem("Solar Panel", "32000", 1);
   tsi.setAmount(si.getAmount());
   tsi.setServiceItem(si);
   tsi.setTarget(target);
   tsi.setServiceItemQty(1);
   return tsi;
 }
 private void saveTargetServiceItem(Target target) throws DuplicateKeyException {
   TargetServiceItem tsi = new TargetServiceItem();
   ServiceItem si = saveAndGetServiceItem("Solar Panel", "32000", 1);
   tsi.setAmount(si.getAmount());
   tsi.setServiceItem(si);
   tsi.setTarget(target);
   tsi.setServiceItemQty(1);
   hibernateTargetServiceItemDao.saveTargetServiceItem(tsi);
   assertEquals(1, hibernateTargetServiceItemDao.getAllTargetServiceItems().size());
 }