AdhocQueryResponseDescriptionBuilder extends AssertionEventDescriptionBuilder { @Override public void setReturnValue(Object returnValue) { if (returnValue == null || !(returnValue instanceof AdhocQueryResponse)) { LOG.warn("Unexpected return value: " + returnValue); } else { response = (AdhocQueryResponse) returnValue; } } AdhocQueryResponseDescriptionBuilder();  AdhocQueryResponseDescriptionBuilder(AdhocQueryResponse response); @Override void buildTimeStamp(); @Override void buildStatuses(); @Override void buildRespondingHCIDs(); @Override void buildPayloadTypes(); @Override void buildPayloadSizes(); @Override void buildErrorCodes(); @Override void setArguments(Object... arguments); @Override void setReturnValue(Object returnValue);  }
@Test public void validRespnoseTypes() { AdhocQueryResponseDescriptionBuilder builder = new AdhocQueryResponseDescriptionBuilder(); AdhocQueryResponse response = getBasicResponse(); builder.setReturnValue(response); assertBasicResponseBuilt(builder); }
@Test public void nullArguments() { AdhocQueryResponseDescriptionBuilder builder = new AdhocQueryResponseDescriptionBuilder(); try { builder.setReturnValue(null); } catch (NullPointerException npe) { fail("Should accept null gracefully"); } }