Examples of GoogleJsonResponseException


Examples of com.google.api.client.googleapis.json.GoogleJsonResponseException

  private static final JsonFactory JSON_FACTORY = new JacksonFactory();
  private static final int HTTP_CODE_NOT_FOUND = 404;
  private static final String REASON_PHRASE_NOT_FOUND = "NOT FOUND";

  public void testCreateException() throws IOException {
    GoogleJsonResponseException exception =
        GoogleJsonResponseExceptionFactoryTesting.newMock(
            JSON_FACTORY, HTTP_CODE_NOT_FOUND, REASON_PHRASE_NOT_FOUND);
    assertEquals(HTTP_CODE_NOT_FOUND, exception.getStatusCode());
    assertEquals(REASON_PHRASE_NOT_FOUND, exception.getStatusMessage());
  }
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.