@Test public void dispatch_shouldCallOnFailureWhenXmlParseErrorOccurs() throws Exception { Robolectric.addPendingHttpResponse(200, "Invalid x-shmail"); apiGateway.makeRequest(new TestGetRequest(), responseCallbacks); assertThat(responseCallbacks.successResponse, nullValue()); assertThat(responseCallbacks.failureResponse, not(nullValue())); assertThat(responseCallbacks.onCompleteWasCalled, equalTo(true)); }
public <T extends ApiResponse> void makeRequest(ApiRequest<T> apiRequest, final ApiResponseCallbacks<T> responseCallbacks) { new RemoteCallTask(responseCallbacks).execute(apiRequest); }
ApiGateway { public <T extends ApiResponse> void makeRequest(ApiRequest<T> apiRequest, final ApiResponseCallbacks<T> responseCallbacks) { new RemoteCallTask(responseCallbacks).execute(apiRequest); } }
ApiGateway { public <T extends ApiResponse> void makeRequest(ApiRequest<T> apiRequest, final ApiResponseCallbacks<T> responseCallbacks) { new RemoteCallTask(responseCallbacks).execute(apiRequest); }  }
ApiGateway { public <T extends ApiResponse> void makeRequest(ApiRequest<T> apiRequest, final ApiResponseCallbacks<T> responseCallbacks) { new RemoteCallTask(responseCallbacks).execute(apiRequest); }  void makeRequest(ApiRequest<T> apiRequest, final ApiResponseCallbacks<T> responseCallbacks); }
ApiGateway { public <T extends ApiResponse> void makeRequest(ApiRequest<T> apiRequest, final ApiResponseCallbacks<T> responseCallbacks) { new RemoteCallTask(responseCallbacks).execute(apiRequest); }  void makeRequest(ApiRequest<T> apiRequest, final ApiResponseCallbacks<T> responseCallbacks);  }