@Test
public void testListReservationsByReservationId() {

  ResourceManager rm = setupResourceManager();
  ClientRMService clientService = rm.getClientRMService();
  Clock clock = new UTCClock();
  long arrival = clock.getTime();
  long duration = 60000;
  long deadline = (long) (arrival + 1.05 * duration);
  ReservationSubmissionRequest sRequest =
      submitReservationTestHelper(clientService, arrival, deadline, duration);
  ReservationId reservationID = sRequest.getReservationId();
  ReservationListResponse response = null;
  ReservationListRequest request = ReservationListRequest.newInstance(
      ReservationSystemTestUtil.reservationQ, reservationID.toString(), -1,
      -1, false);
  try {
    response = clientService.listReservations(request);
  } catch (Exception e) {
    Assert.fail(e.getMessage());
  }
  Assert.assertNotNull(response);
  Assert.assertEquals(1, response.getReservationAllocationState().size());
  Assert.assertEquals(response.getReservationAllocationState().get(0)
      .getReservationId().getId(), reservationID.getId());
  Assert.assertEquals(response.getReservationAllocationState().get(0)
      .getResourceAllocationRequests().size(), 0);
  rm.stop();
}