### Question:
BookingDaoESImp extends BaseDaoESImp implements BookingDao { @Override public void updateBookingBucketWithAllocatedAmount(String bookingBucketId, Map<String, Double> newAllocatedAmount) throws IOException { UpdateRequest updateRequest = new UpdateRequest(this.bookingBucketsIndex, ES_TYPE, bookingBucketId); Map<String, Object> requestMap = new HashMap<>(); requestMap.put("allocated_amount", newAllocatedAmount); updateRequest.doc(requestMap); esclient.update(updateRequest, WriteRequest.RefreshPolicy.WAIT_UNTIL.getValue()); } BookingDaoESImp();  BookingDaoESImp(Properties properties); @Override void removeBooking(String bookingId); @Override String createBooking(Booking booking); @Override Map<Day, List<Booking>> getBookings(Set<Day> days); @Override List<Booking> getBookings(String advId); @Override Booking getBooking(String bookingId); @Override Map<Day, List<BookingBucket>> getBookingBuckets(Set<Day> days); String createBookingBucket(BookingBucket bookingBucket); @Override boolean lockBooking(); @Override void unlockBooking(); @Override BookingBucket getMaxBookingBucketPriority(String day); @Override void updateBookingBucketWithAllocatedAmount(String bookingBucketId, Map<String, Double> newAllocatedAmount); @Override List<BookingBucket> findBookingBucketsWithAllocatedBookingId(String bookingId); @Override void removeBookingBucket(BookingBucket bookingBucket);  }### Answer:
@Test public void updateBookingBucketWithAllocatedAmount() throws IOException { String day = "20180105", bookingId = "test_bkid_1"; List<String> prvBkOrder = new ArrayList(); BookingBucket bb1 = new BookingBucket(day, bookingId, prvBkOrder, 1); BookingDaoESImp bkDaoImp = new BookingDaoESImp(DEF_PROP); bkDaoImp.setESClient(DEF_ESCLI); String bbId = bkDaoImp.createBookingBucket(bb1); Set<Day> set = new HashSet(); set.add(new Day(day)); int prv = bkDaoImp.getBookingBuckets(set).size(); bkDaoImp.updateBookingBucketWithAllocatedAmount(bbId, new HashMap()); assertEquals(prv, bkDaoImp.getBookingBuckets(set).size(), 0); }