### Question:
RoundRobinDistributionSchedule implements DistributionSchedule { @VisibleForTesting static WriteSet writeSetFromValues(Integer... values) { WriteSetImpl writeSet = WriteSetImpl.create(0, 0, 0); writeSet.setSize(values.length); for (int i = 0; i < values.length; i++) { writeSet.set(i, values[i]); } return writeSet; } RoundRobinDistributionSchedule(int writeQuorumSize, int ackQuorumSize, int ensembleSize); @Override WriteSet getWriteSet(long entryId); @Override WriteSet getEnsembleSet(long entryId); @Override AckSet getAckSet(); @Override AckSet getEnsembleAckSet(); @Override QuorumCoverageSet getCoverageSet(); @Override boolean hasEntry(long entryId, int bookieIndex); @Override BitSet getEntriesStripedToTheBookie(int bookieIndex, long startEntryId, long lastEntryId);  }### Answer:
@Test public void testMoveAndShift() { DistributionSchedule.WriteSet w = writeSetFromValues(1, 2, 3, 4, 5); w.moveAndShift(3, 1); assertEquals(w, writeSetFromValues(1, 4, 2, 3, 5)); w = writeSetFromValues(1, 2, 3, 4, 5); w.moveAndShift(1, 3); assertEquals(w, writeSetFromValues(1, 3, 4, 2, 5)); w = writeSetFromValues(1, 2, 3, 4, 5); w.moveAndShift(0, 4); assertEquals(w, writeSetFromValues(2, 3, 4, 5, 1)); w = writeSetFromValues(1, 2, 3, 4, 5); w.moveAndShift(0, 0); assertEquals(w, writeSetFromValues(1, 2, 3, 4, 5)); w = writeSetFromValues(1, 2, 3, 4, 5); w.moveAndShift(4, 4); assertEquals(w, writeSetFromValues(1, 2, 3, 4, 5)); }