@Override
  public void handleRequestWithRestLiResponse(RestRequest request, RequestContext requestContext, Callback<RestLiResponse> callback)
  {
    if (!isMultipart(request, requestContext, callback))
    {
      _restRestLiServer.handleRequestWithRestLiResponse(request, requestContext, callback);
    }
  }
@Test(dataProvider = "restOrStream")
  public void testHandleRequestWithRestLiResponseError(final RestOrStream restOrStream) throws Exception
  {
    final StatusCollectionResource statusResource = getMockResource(StatusCollectionResource.class);
    EasyMock.expect(statusResource.get(eq(1L))).andReturn(null).once();
    replay(statusResource);

    Callback<RestLiResponse> restLiResponseCallback = new Callback<RestLiResponse>()
    {
      @Override
      public void onSuccess(RestLiResponse restLiResponse)
      {
        fail("We should not get a success here. The server should have returned a 404!");
      }

      @Override
      public void onError(Throwable e)
      {
        RestLiResponseException restLiResponseException = (RestLiResponseException) e;
        assertEquals(restLiResponseException.getRestLiResponse().getStatus(), HttpStatus.S_404_NOT_FOUND,
            "We should get a 404 back here!");
        EasyMock.verify(statusResource);
        EasyMock.reset(statusResource);
      }
    };

    if (restOrStream == RestOrStream.REST)
    {
      RestRequest request = new RestRequestBuilder(new URI("/statuses/1"))
          .setHeader(RestConstants.HEADER_RESTLI_PROTOCOL_VERSION, AllProtocolVersions.BASELINE_PROTOCOL_VERSION.toString()).build();

      _server.handleRequestWithRestLiResponse(request, new RequestContext(), restLiResponseCallback);
    }
    else
    {
      StreamRequest streamRequest = new StreamRequestBuilder(new URI("/statuses/1"))
          .setHeader(RestConstants.HEADER_RESTLI_PROTOCOL_VERSION, AllProtocolVersions.BASELINE_PROTOCOL_VERSION.toString())
          .build(EntityStreams.emptyStream());

      _server.handleRequestWithRestLiResponse(streamRequest, new RequestContext(), restLiResponseCallback);
    }
  }